Today I’m going to talk about how I’ve decided to go down the absolute nerd path towards IM. I simply wasn’t satisfied with Facebook’s XMPP chat on my browser and heard somewhere on the corners of the internet that it was possible to use it’s Messenger’s MQTT protocol on an IRC client via Bitlbee. I was down for trying that.
The idea was to install this client on my VPS so that it could be up and running 24/7 in a way that I’d never miss a single message. Tmux was the key into detaching and attaching from the Weechat session so that it’d be always up and reachable from any location that I could access my VPS. All I would need would be my private key and an ssh enabled terminal.
First thing I’ve had to do was installing Weechat latest version on my VPS, (the one that comes with debian’s native repositories was slightly outdated). This link gives a fairly good explanation on how to achieve so: https://weechat.org/download/debian/. Just click on installation instructions and choose your distro. Add the repository, gpg keys, apt-get update it, apt-get install weechat [...] and voilà. I had the latest version of Weechat installed on my VPS.
Next step was setting up Bitlbee to be able to send and receive Facebook messages via MQTT on the client. This link gives very precise instructions on such: https://wiki.bitlbee.org/HowtoFacebookMQTT. Same principle: add repositories, install gpg keys, apt-get update, apt-get install bitlbee-facebook and kudos.
Then it would be all about starting Weechat in a Tmux session, setting up with some hackity hacks and that was it. All set and done.
Later I’ve added Freenode and Gitter and plan on adding Slack support. Also considering developing a Whatsapp integration for Weechat in the future.
It's worth mentioning that I am also able access my Weechat ever-running instance via my mobile by ssh'ing into my box via JuiceSSH and tmuxing it up.
Here are some code snippets that helped me through the process of making this whole setup persistent and useful: