Configuring screen and IRSSI 

Today, I had a power cut when I was half-way through an important e-mail and it so happened that for some reason, the UPS didn’t take over. I tried to keep calm and convinced my dad to get new batteries for the main home inverter. But what I don’t like to do is to type four GRUB commands on rebooting and then open a terminal once the system boots, run screen in it, create 9 tabs and fill them with the appropriate programs by my conventions and tell irssi to join all the channels in the right order I want their windows to be in.

So I decided that it’s high time I configured my ~/.screenrc and ~/.irssi/config

[I’m yet to find out how to use both of them together, effeciently. So this post talks only about separately configuring them.]

So here’s what I did:

Configuring screen:
I lost the article that I got via Google. It basically told me how to auto-open tabs using screen and run stuff in them. The entry for that in ~/.screenrc is simple:

screen -t <tab name> <tab number> [command to execute]

So I now have entries like:

screen -t mixer 0 alsamixer
screen -t IRC 1 /usr/bin/irssi
screen -t MOCP 5 mocp
screen -t Gen1 7

in my ~/.screenrc

Another interesting thing that KMap taught me looks like
bind <some key> other
This alternates between tabs like Alt+Tab does in most window managers. This isn’t working for me, I still need to take a look at it.

Configuring IRSSI

This page told me almost all that I needed. I still haven’t been able to auto-load a perl script that notifies me if somebody pings me on IRC and have to still find out how to automatically do /msg nickserv identify after login.

The script for notifying me of pings: I modified a script to popup a GTK+ dialog, by Luke Macken, with something simpler:

  1. Contents of ~/.irssi/scripts/

use Irssi;
sub notify {
my ($dest, $text, $stripped) = @_;
my $server = $dest->{server};
return if (!$server || !($dest->{level} & MSGLEVEL_HILIGHT));
system("sudo lpdevctl bulb; sleep 0.5; sudo lpdevctl bulb;");
Irssi::signal_add('print text', 'notify');

This thing flashes a bulb, with an on-state for half second.