Render desktop notifications with pianobar information
Switch branches/tags
Nothing to show
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.



This utility is called from pianobar. When the status changes, a notification using the Desktop notification system is displayed. It has only been tested in Linux, using the Desktop notification system implemented by the Galago project.

My pianobar config file (~/.config/pianobar/config) includes

event_command = pianobar-notify

To install this app, for the time being, copy or soft-link src/pianobar-notify to ~/bin or a directory in your path.

Required modules:

Run the requirement check script (which requires Test::More) by running:

perl src/

I had to add a missing feature to Desktop::Notify::Notification. The patch is:

--- a/blib/lib/Desktop/Notify/   2009-12-24 20:09:23.000000000 -0500
+++ b/blib/lib/Desktop/Notify/   2010-11-17 17:51:45.000000000 -0500
@@ -5,7 +5,7 @@
 use base qw/Class::Accessor/;
-Desktop::Notify::Notification->mk_accessors(qw/summary body timeout/);
+Desktop::Notify::Notification->mk_accessors(qw/summary body timeout app_icon/);
 =head1 NAME
@@ -78,7 +78,7 @@
         $self->{id} = $self->{server}->{notify}
                                  $self->{id} || 0,
-                 '',
+                 $self->{app_icon} || '',

which basically adds an accessor for app_icon and sends app_icon to the server.

I have a call to _show_in_awesome from the _display method. If you are not using Awesome, or don't have musiccover defined in your rc.lua ($HOME/.config/awesome/rc.lua), comment out the line in _display that calls it (currently 144, but it will change).

The commented out section should look like:

# $self->_show_in_awesome(...);