Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How can I add a notification of some sort (like playing a .wav file or creating a pop-up on the status bar) when a process finishes.

For example, I am compiling a program that takes a couple of hours to finish. I would like to hear/see some sort of message when it completes compiling. Is there a tool for doing this (like tying an alarm program to the pid of a process) or something like that?

share|improve this question
Possible duplicate of Desktop notification when long running commands complete – muru Mar 6 at 20:09
up vote 6 down vote accepted

One way to get a popup (a desktop notification) is to install the libnotify-bin package, then add "alert" to your command line, like this:

./configure && make && alert

Note that "alert" is a convenience alias, if you type:

alias alert

you will see that behind the scenes it calls the notify-send command, which has a bunch of interesting options, so you may want to define your own alias to call notify-send in a way that better suits you.

share|improve this answer
Very helpful, Thank you – Lelouch Lamperouge Jan 18 '12 at 21:06
I would suggest running something like make && notify-send "make" "done" || notify-send "make" "an error occured". To send a message even if make fails. – Zoke Jan 18 '12 at 22:14

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.