random status in Pidgin :- fortune

There is a nice utility called 'fortune' for linux. Basically a database of funny/witty quotes accumulated over decades which can be read either directly from flat files or using the 'fortune' front-end.

What can you use it for? Display random quotes in your mail signature (with due references/credits), on your home page or IM status :P

#!/bin/bash
while true :;

do
MSG=`fortune -ae`
zenity --question --text="$MSG" && (purple-remote "setstatus?message=$MSG" && sleep 1800);
done;
Make sure you have zenity and fortune packages installed.

Start pidgin and then this script. It will get a new random status every 1800 seconds and ask whether you want it as status, the process repeats immediately if you press cancel, and status is set otherwise.

'fortune' is used for name sake here. You can pull in random statuses from some web page (and probably scrape them), or some RSS feed if available, or from your own compiled database of statuses, reading one at random.

This is what you do when you are bored to core sitting in an office on Monday afternoon waiting for the benchmarks to complete.

2 comments:

  1. tried.
    but it's not for me as long as status messages are concerned because i cant let some script decide my status of mind!
    but this is worth trying..
    jst a bit of info.. on ubuntu, u need "libpurple-bin" installed for purple-remote.

    ReplyDelete