Module: Fabriq::CLI
Instance Attribute Summary collapse
-
#skype ⇒ Object
Returns the value of attribute skype.
Instance Method Summary collapse
Instance Attribute Details
#skype ⇒ Object
Returns the value of attribute skype.
5 6 7 |
# File 'lib/fabriq/cli.rb', line 5 def skype @skype end |
Instance Method Details
#list_available_rooms ⇒ Object
20 21 22 23 24 25 26 27 |
# File 'lib/fabriq/cli.rb', line 20 def list_available_rooms cli_out "\n*** Available Rooms: ***\n" skype.rooms.each do |room| topic = room.topic == "" ? "<not set>" : room.topic cli_out "* ID: %s\t Topic: %s" % [room.id, topic] end end |
#run(args) ⇒ Object
11 12 13 14 15 16 17 18 |
# File 'lib/fabriq/cli.rb', line 11 def run(args) case args.first when "rooms" list_available_rooms end exit(0) end |