Facebook now supports XMPP. Yay.
Using Facebook Chat in bitlbee is pretty straight forward (I am running 1.2.4, older versions of bitlbee require a bit more tweaking, consult the manual).
For Facebook Chat through XMPP to work you need to set a Facebook username.
In the &bitlbee channel
account on
that’s it.
Edit (04-03-2011): As some has pointed out, you need to input your username in lowercase.
Facebook users are listed by their Facebook user id (uXXXXXXX) so you have to rename them manually, unless you are using irssi.
Download this script to ~/.irssi/scripts and load it
(Note: This script only renames your Facebook contacts – The original version which renames all contact but does not handle international characters really well is available here)
Now each of your contacts will be renamed based on their real name in their vCard.
Remember to symlink to script to ~/.irssi/scripts/autorun if you wish to auto-load it.
Thanks!
I’ve been beating my head against the wall for the past two hours trying to get the nicks to be human readable without having to rename them all by hand.
This is a small “fix” to only rename facebook contacts.
I have emesenne and another Jabber address on my bitlbee, and this script try to rename all my buddies >command(“whois $nick”);
- }
+
+ if($host eq “chat.facebook.com”) {
+ if ($channel =~ m/($bitlbeeChannel)/ and $nick =~ m/$username/) {
+ $nicksToRename{$nick} = $channel;
+ $server->command(“whois $nick”);
+ }
+ }
}
sub whois_data
Paste fail.
Try here: http://www.effervescence.be/paste/80516621
Great guide!
Thanks for the rename script.
The script is a little too efficient, it also renames all your msn and icq contacts.
Attached is a modified version that only renames facebook contacts and doesn’t whois existing contacts with non-facebook names.
That bitlbee_rename.pl script works really badly if you have contacts with non-ASCII characters so I modified it to use Text::Unidecode to transliterate the names to ASCII.
Super. I’ve been meaning to fix that particular problem but haven’t had the time yet. I’ll link to your version instead.
Thanks.
/allan
I moved the script to its own repo at irssi-bitlbee-facebook-rename.
I’ve upgraded to 1.2.4 and it doesn’t work for me. Everytime I will connect:
root@> jabber(username@chat.facebook.com) – Couldn’t log in: Authentication failure
root@> jabber(username@chat.facebook.com) – Logging in: Signing off..
:-(
Did you set a password for the account? I haven’t seen any problem nor heard of any from any of my friends.
You can set a new password like so
account set/password facebook_password
*bonk* I found my failure. My Facebookusername is “Oszedo” and i wrote “Oszedo@chat…” as username in bitlbee. With “oszedo@chat…” it works fine! ;-)
The script doesn’t load because of errors:
<param name="bgcolor"
(Might be a runaway multi-line "" string starting on line 272)
(Missing operator before bgcolor?)
String found where operator expected at (eval 520841) line 273, near "bgcolor" value=""
the rename script does not work here. this is the output:
18:19 Can’t locate Text/Unidecode.pm in @INC (@INC contains: /home/login/.irssi/scripts /usr/share/irssi/scripts /usr/lib/perl/5.10 /etc/perl
/usr/local/lib/perl/5.10.1 /usr/local/share/perl/5.10.1 /usr/lib/perl5 /usr/share/perl5 /usr/share/perl/5.10 /usr/local/lib/site_perl .) at
/home/login/.irssi/scripts/facebook_bitlbee_rename.pl line 9.
18:19 BEGIN failed–compilation aborted at /home/login/.irssi/scripts/facebook_bitlbee_rename.pl line 9.
whats wrong?
Hi,
you need to install the Text::Unidecode Perl module
As said in Oszedo’s comment, I needed to lower-case my facebook username. Maybe you could emphasize that in your post, it’s been very helpful for me otherwise.
You don’t have to use a rename script, just use account set #/nick_source full_name
http://wiki.bitlbee.org/HowtoFacebook