Growl is a “global notification system” for OS X. Applications can use the Growl framework to display notifications to the user. I use Growl with Adium, and it works wonderfully.

The Growl package (download) includes a utility called growlnotify, which can be used to display notifications using the command-line. I use the following bash script (growlexec) to run a specified command and display a notification when done:

#!/bin/bash

$*

if [ $? -eq 0 ]
then /usr/local/bin/growlnotify -m "\"$*\" done (SUCCESS)"

else /usr/local/bin/growlnotify -m "\"$*\" done (FAILED)"
fi

Here is a screen-shot of growlexec causing a Growl notification to be displayed after a successful nmap run:

image