headphono.us

Avatar

Pras Sarkar blogs about web technology, music, social networks, digital identities and other random things.

todo.txt and Multi-user IM bot

I started using the minimal but feature-rich todo.txt by Gina Trapani today. Its got a great set of features (lists, priorities, projects, contexts, etc). Its minimal and coupled with the AIM client, you don’t necessarily have to always have a Terminal window open to interact with it. Adium does just fine.

A few tweaks you may want to use to further enhance. I found myself typing “ls” for “list” too often and then having to correct it. To have “ls” also work as “list”, change line 271 from 271: "list" ) to 271: "list" | "ls" ). You can also do the same for “do” (or “done” as I like it). Change line 254 from 254: "do" ) to 254: "do" | "done" )

Finally, I edited the todobot.pl script to support multi-user control. Download the updated todobot.pl script. Rename the file to todobot.pl. You can add multiple usernames by separating them with commas like: my $commander = 'username1, username2, username3';

Update: I’ve changed the todobot.pl to include a “die” command so that you can take it offline remotely. This signs the bot out of AIM, and also gracefully kills the todobot.pl script. This is included in the todobot.pl script above.

Now you can run the script as perl todobot.pl > /dev/null & (pipes the output to null so it doesn’t clutter up your Terminal and also pushes the process to the background). This is where the “die” command comes in handy – no more having to figure out the process id to kill your IM bot.

Please email bugs to mxz at headphono.us

Tags

No Comments, Comment or Ping

Comments are closed.

My Lifestream

My shenanigans around the web