How to hook twitter into a IRC channel
Posted on Dec 12, 2006
So I love playing with fancy things. And twitter is one of those fancy things. In fact - it has been on my mind quite a bit. Like I said a couple posts ago, I have been thinking about writing a utility that will set your IM status based on your twitter update. It will be awesome. But in the meantime I whipped up a quick hack to help yall hook your twitter into your IRC application.
The first step is to secure a aim screenname that you are not using. It is best to get one that isn't at all known. Because any traffic to the screenname will be reflected in the channel. You can sign up for a new one here. Once you get a really shiny and new screen name, you can go to twitter.com and register it with your twitter account. I made a new twitter account for my IRC channel so that I can follow all my friends that are on IRC.
The next step is a bit more complicated. You are going to have to be ready to get your hands a bit dirty in a shell. It isn't really rough, but if you are not ready to run a Perl script - then read up and try it out! So go and get my quick little aim2irc.pl hack I made tonight. It is just a simple Perl script that logs into aim with the new screenname you got and then logs into your IRC channel.
So when you grab the script and run it with a
[nata2] jhr > perl ./aim2irc.pl
It will log into aim, log into IRC and then sit there waiting to be messaged by whomever knows your fancy new screenname - which should be the twitter app. So then when your buddies update their twitter timeline it will message your new aim name and that will then be sent to your IRC channel. like so:
01:33|<``twitter> harper: About to finish the second season of lost. And my IRC bot is almost done. I rule!
So this is sent into my channel #corporate from my twitter status update. It shows up as coming from my twitter bot and shows exactly what the aim message says - which fancy enough is a good amount of information for an IRC bot for twitter to share.
- Twapp - a quick hack to update and view twitter published on Dec 7, 2006
- Linux distribution for older folks. published on Dec 5, 2006
- stuff.harperreed.org. Last nights web-dev itch published on Nov 24, 2006
- Hacking mobile voicemail with Asterisk and caller ID spoofing published on Sep 24, 2006
- Thoughts about The DECK and PageRank. published on Sep 18, 2006