class Lita::Handlers::CircleciCommander

Attributes

circle[W]

Public Instance Methods

circle() click to toggle source
# File lib/lita/handlers/circleci_commander.rb, line 17
def circle
  @circle ||= CircleCi.new
end
rebuild(response) click to toggle source
# File lib/lita/handlers/circleci_commander.rb, line 11
def rebuild(response)
  build_id = response.message.body.split.last
  response.reply "#{response.user.name} is rebuilding #{build_id}."
  circle.rebuild(build_id.delete("#").to_i) || response.reply("Error talking to CircleCi :(")
end