Sha256: 9f13fd0d1cdb47688133213cd32dcde9eb4258c3dfe8e8e4fae95ebfefa7ff40

Contents?: true

Size: 532 Bytes

Versions: 8

Compression:

Stored size: 532 Bytes

Contents

$:.unshift File.join(File.dirname(__FILE__), *%w[../../lib])

require 'rubygems'
require 'erlectricity'
require 'tinder'

domain, email, password, room_name = *ARGV
campfire = Tinder::Campfire.new domain
campfire.login email, password
room = campfire.find_room_by_name room_name

receive do |f|
  f.when([:speak, Any]) do |comment|
    room.speak(comment)
    f.receive_loop
  end

  f.when([:paste, Any]) do |comment|
    room.paste(comment)
    f.receive_loop
  end

  f.when(Any) do |obj|
    p obj
  end
end

room.leave if room

Version data entries

8 entries across 8 versions & 3 rubygems

Version Path
mojombo-erlectricity-1.0.0 examples/tinderl/tinderl.rb
mojombo-erlectricity-1.0.1 examples/tinderl/tinderl.rb
mojombo-erlectricity-1.0.2 examples/tinderl/tinderl.rb
erlectricity-funbox-1.1.2 examples/tinderl/tinderl.rb
erlectricity-1.1.1 examples/tinderl/tinderl.rb
erlectricity-1.1.0 examples/tinderl/tinderl.rb
erlectricity-1.0.0 examples/tinderl/tinderl.rb
erlectricity-1.0.1 examples/tinderl/tinderl.rb