It's no surprise that Bitlbee is my chat client of choice. After all, I've blogged about it before. So, when I heard rumors that Facebook would be releasing their chat to outside clients over XMPP, I was excited to see the day when I could add it to my running Bitlbee instance. Lo and behold, that day has come.
Adding your Facebook account to Bitlbee is rather painless, as it is with any other account. The only catch, is you have to have a Facebook username set before you can continue. Once that is set, in Bitlbee, from your "&btilbee" status window, you can add the account:
account add jabber <username>@chat.facebook.com <password> save account on
That's it! You should be up and running with a new XMPP connection to the Facebook chat. However, rather quickly, you'll notice that the usernames in your "blist" roster are their user identification number on Facebook, rather than their name. Something like "u123456789". Who is that you wonder? Well, in your "&bitlbee" window, you could run:
Then, using that information, you could rename them one-by-one as they login. However, this is a pain. Fortunately, if you're running Bitlbee with Irssi, then there is an Irssi Perl script for renaming these automatically for you, as they login. You can find that script here. Save it as "bitlbee_rename.pl" in your "~/.irssi/scripts directory, create a symlink in the autorun directory, load it, and you're set. Here's what you would do behind the command line:
wget -O ~/.irssi/scripts/bitlbee_rename.pl http://browsingtheinternet.com/temp/bitlbee_rename.txt ln -s ~/.irssi/scripts/bitlbee_rename.pl ~/.irssi/scripts/autorun/bitlbee_rename.pl
Now in Irssi, load it:
Now, each of your Facebook buddies will have their user ID number renamed to "FirstnameLastname" format. The script only works for Facebook chat, so no worries about it mucking up other XMPP connections, and it only renames buddies that haven't already been renamed. It also saves it to your Bitlbee config (which is /var/lib/bitlbee/username.xml) every time it renames a buddy.
So, there you go. Bitlbee, XMPP and now Facebook, married together. What a beautiful relationship.