Working Remotely? Thinking about it?

Are you a member of a geographically dispersed team? Are you thinking of working remotely, or hiring remote developers? Wide Teams is my new blog and podcast for distributed teams. Check it out for getting started guides, tips and best practices, news, interviews, screencasts, and more all about working remotely and collaborating with wide-spread teams.

Announcing Firetower – A command-line interface to Campfire

2010 July 11
by avdi

OK, this is pretty early stuff but it’s already usable and I think it has a lot of potential.

BaldMountainLookoutFiretower is a command-line interface to Campfire. It’s currently for Linux systems only, but there’s no reason it can’t be extended to work on OS X as well.

I created it because I needed a command-line interface to Campfire that supported the current streaming Campfire API. I also wanted a bit more flexibility than existing tools provided.

You can read all the details at the Github page, but in a nutshell Firetower provides two services:

  1. A way to post messages and code snippets to Campfire from the command line; and
  2. A daemon which will monitor any number of campfire rooms (in any number of accounts) and take user-configurable action when events (such as new messages) occur.

The latter service is particularly flexible: it can be used to do anything from playing a sound when someone says something in a Campfire room, to implementing IRC-style bots which monitor rooms for keywords and respond accordingly.

For instance, here’s a simple (and HIGHLY UNSAFE!) Ruby eval-bot which you could drop into ~/.firetower/firetower.conf:

receive do |session, event|
  if event['type'] == 'TextMessage' && event['body'] =~ /^!eval (.*)$/
    event.room.account.paste!(event.room.name, "Eval result:\n" + eval($1).to_s)
  end
end

Which is triggered when anyone in the room prefaces a message with “!eval”:

campfire_eval2

Patches, suggestions, and bug reports welcome!

Bookmark and Share
Creative Commons License
This work, unless otherwise expressly stated, is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 3.0 United States License.

Related posts:

  1. Greenletters: Painless automation and testing for command-line applications
  2. ANN FireTower 0.0.4
  3. Using Hashes as Caches
  4. Announcing Ninja-Patching!
  5. Sustainable Development in Ruby, Part 1: Good Old-Fashioned Inheritance
  • Hey Avdi, this is pretty awesome, and we're already making good use of it. Right now, it's mostly for hilarity (ship it! pastes a ship it squirrel, for example), but we got some interesting actually useful ideas in the work.

    Also, the 'Firetower is a command-line interface to Campfire' link is broken. Guessing you it was originally named firestarter.
  • Great to hear!

    Thanks, I fixed the link. Must have had Prodigy in my head when I wrote it, because it was never called firestarter.
blog comments powered by Disqus