Hacking Prowl and Irssi
The moment I stumbled upon Prowl (a new iPhone App that routes Growl notifications to your iPhone via Apple’s push service) I knew I would find some powerful uses for it.
At Tera-Byte, several of my colleagues telecommute. In order to stay in constant communication with each other, we all use good ol’ IRC. In order to be readily available and allow quick roaming from one location to an other, I use Irssi‘s proxy module which runs continuously within a screen session on my co-located server.
On my Desktops and iPhone I run Colloquy which connects to my Irssi proxy. Although push capabilities are planned for Colloquy, it’s not ready yet. Prowl appeared to be the perfect band-aid for the situation.
My original plan was to use Prowl as intended and have Colloquy’s Growl notifications directed to my iPhone. This had some limitations, most importantly it required leaving Colloquy running on my work desktop.
Fortunately the developer of Prowl provided an example perl script to push notifications to Prowl independently of Growl. I’ve never attempted to work with Irssi script’s, but it appeared I had all the required pieces to build something clever.
I downloaded BCOW’s awayproxy.pl script as a starting point and began to hack away at it. The result: prowlnotify.pl.
Change the prowluser and prowlpass lines then load this script into Irssi. While you’re connected to your proxy the script will do nothing. When your last IRC client disconnects it will push all subsequent public messages containing your nick as well as private messages to your iPhone via Prowl. How sweet it is!
Of course, this post would not be complete without an obligatory screenshot. Nobody appeared to have anything to say today, so I was down and out. In my desperation I called upon cshaiku to grace me with his words of wisdom:
Update: I have now updated this script to use the new Prowl apikeys. Editing the script is no longer required. Simply copy your Prowl key into ~/.prowlkey.
Another update: Every time I try to search Google for an Irssi plugin to work with Colloquy’s push notification feature instead of using Prowl I find my own page. Amusing, but not helpful!
Just found a Colloquy push script for Irssi written by Nicolas Pouillon that does exactly that.
July 8th, 2009 at 12:14 am
Seriously? You had to tell the world about our little secret!?
I’m taking the kids. You can have the duckie. He always loved you anyways.
*sniff*
😛
July 16th, 2009 at 3:52 pm
Just wanted to drop you two lines:
(1) Thank you for this script. Just testing it out not 5 minutes ago and worked like a charm.
Using this script and screen_away, I have a perfect combination of notification.
(2) This has inspired me to find other ways to use Prowl, and I’ve already whipped up a NAGIOS event notification via Prowl script, and have already put it to use at work.
Thanks for the script, thanks for the inspiration.
July 28th, 2009 at 2:44 pm
Thanks for the script 🙂 Interesting use of the irssi proxy, I just SSH into my machine from whatever computer instead.
August 7th, 2009 at 12:00 am
[…] IRC fans can also find some useful Prowl hacks here. […]
September 2nd, 2009 at 1:00 pm
Works like a Charm.. thanks! 🙂
October 3rd, 2009 at 3:06 pm
Well this didn’t work for me…
I generated API key, pasted it into the .prowlkey and loaded the script in the irssi.
Then i closed my irc-client and my friend tried sent me couple of private messages but i got no new notifications on my iphone.
Is there log or something where i could check what is going wrong?
January 31st, 2010 at 7:27 am
[…] prowlnotify.pl – This script is cool for those who have an iPhone. When your connection is set to away, either by /away or by disconnecting from screen (using the next script), Prowl Notify will use APIs to send your message to your iPhone. It is quite cool if you have an iPhone like I do. […]
March 29th, 2010 at 5:19 pm
Hmm. This script seems to cause irssi to seg fault whenever my nick is hilighted. D’oh.
March 31st, 2010 at 12:13 pm
This is really great – worked like a charm. Thanks so much for publishing the script!
Chris
June 13th, 2010 at 8:47 am
Hi,
This looks great, however I get the following;
15:38 -!- Irssi: From Irssi::Script::prowlnotify:
15:38 -!- Irssi: Sending prowl
15:38 -!- Irssi: From Irssi::Script::prowlnotify:
15:38 -!- Irssi: Notification not posted: 500 Can’t locate object method “new” via package “LWP::Protocol::https::Socket”
Even though I have the packages installed.
Any ideas?
September 8th, 2010 at 12:38 pm
Luke: if you’re using Debian or Ubuntu, try to install libcrypt-ssleay-perl and libcrypt-ssleay-perl, restart irssi and try again. Worked for me.
October 15th, 2010 at 3:15 am
I use debian, and, i having probl;ems with irc and perl altogether, so when i saw this, i kinda saw some glimmer of hope 😛 but, i realised it has same name 2 times??? I assume a type but, could you please provide with the correct libs needed exactly? not just the one i see there.. btw: installing xchat and eggdrop adds some of the modules for irc but… with perl, i am experiencing problems running even a simple irc tailbot :s so am hoping this ;
libcrypt-ssleay-perl and libcrypt-ssleay-perl
is somehow a type and, it means there is one packge or, just type ?? am surprised no deb users have spoken up yet…but anyhow! thanks!
February 12th, 2011 at 2:12 am
I used cpan to install Crypt::SSLeay and openssl-devel and then put “use Crypt::SSLeay;” near the top and it worked for me
February 18th, 2011 at 5:21 pm
Thanks for this script, it’s working well for me but there is one thing that bugs me, I’m using this together with autoaway.pl and when the script runs it causes autoaway to return me to online state and reset the away counter. I’ve asked around #irssi about this and they suggest I merge the two scripts. I’m not sure if the problem could be solved in prowlnotify.pl or autoaway.pl without merging them as I’m not familiar with perl. Has anyone else ran into this issue and maybe found a solution? I’ll post back if I manage solve it.
March 17th, 2011 at 10:53 am
@m3lvin
I was googling around for a script like this, found this, but it didn’t play well with autaway.pl. While looking around I found a fork of this script, however, it’s focusing on the use of autoaway.pl instead of awayproxy.pl. Works like a charm for me.
http://sniker.codebase.nu/post/14#Prowl.pl
April 15th, 2011 at 8:56 pm
Hi, I recently release a prowl-like application for the Android. I am contacting you to ask if you have any interest on adding Android support on your application. Please contact me if you do and I could be of any help. Thank you.
May 25th, 2011 at 3:36 pm
[…] away and forwards them to my iPhone using Prowl. For this I use a ready made and excellent script (prowlnotify.pl) written by Denis […]
May 25th, 2011 at 3:58 pm
Hi,
Just wanted to say thanks for the script. Have been using it for some time now. Instead of using it with autoaway though, I use it in conjunction with another script which uses my phone to detect whether I’m at my desk or not:
http://qatoolbox.wordpress.com/2011/05/25/configuring-irssi-with-iphone-and-prowl/
Cheers!
June 27th, 2011 at 2:10 pm
[…] on my old desktop for use as an IRC proxy. The wonderful part was finding Denis Lemire’s prowlnotify.pl script, which sends push notifications to my iPhone via Prowl, an iPhone app that accepts grow […]