Class: KStrano::CampfireHelper

Inherits:
Object
  • Object
show all
Defined in:
lib/helpers/campfire_helper.rb

Class Method Summary collapse

Class Method Details

.speak(campfire_account, campfire_token, campfire_room, message = "") ⇒ Object



6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
# File 'lib/helpers/campfire_helper.rb', line 6

def self.speak(, campfire_token, campfire_room, message="")
  ## extracted this to here, because i don't know how to call capistrano tasks with arguments
  ## else i just had to make one capistrano task which i could call
  if !.nil? && !campfire_token.nil? && !campfire_room.nil?

    Broach.settings = {
      'account' => ,
      'token' => campfire_token,
      'use_ssl' => true
    }

    room = Broach::Room.find_by_name campfire_room

    if !room.nil?
      room.speak message
    end
  end
end