There you go.
require 'rubygems'
require 'xmpp4r'
require 'xmpp4r/roster'
puts 'Connecting ...'
client = Jabber::Client.new(ARGV[0]).connect('talk.google.com')
client.auth(ARGV[1])
puts 'Receiving'
roster = Jabber::Roster::Helper.new(client)
roster.add_presence_callback do |roster_item, old_presence, new_presence|
if new_presence
from = roster_item.iname || "#{new_presence.from.node}@#{new_presence.from.domain}"
if new_presence.status
puts "#{from}: #{new_presence.status}"
end
end
end
client.send(Jabber::Presence.new)
Thread.stop
client.close
Run from the command line:
$ ruby distwit.rb <jabber_id> <password>
Connecting ...
Receiving
Andre Lewis: Away
Matthieu Riou: Enjoying a JavaOne couch
Matthieu Riou: Entertaining Assaf
Alexis Midon: hacking in a couch @community-one
Now just wait for your friends to status away using their IM client.
And don’t forget, please yo-yo the rrm.

links for 2008-05-09 « Breyten’s Dev Blog
Bre Pettis – A Dream – Open Source Distributed Microblogging at I Make Things