i am developing some software with a significant build time, so i want to execute the build command and play a noise once it is finished. two questions:

  1. how do i make some noise from the command line (Redhat Enterprise Linux 5)?
  2. i am doing the build on a remote machine, so is there something like X11 forwarding for sound that will play the noise on my machine?

if #2 isn't possible/easy i guess i could just execute the build command on the remote machine and play the noise locally. thanks for the help.

link|improve this question

78% accept rate
feedback

2 Answers

up vote 4 down vote accepted

You can echo the BEL character, perhaps multiple times, from your build script.

For example:

#!/bin/sh
echo "\a\a\a"

The above example will print the BEL character 3 times. Thus, the PC speaker should emit 3 beeps.

link|improve this answer
Note that if you're using Bash instead of sh you'll need echo -en "\a\a\a" (the -n` suppresses the newline). Also, in either case I only get one "ding". You can loop with a short sleep to make it work. – Dennis Williamson Jan 15 '10 at 16:58
feedback

What about printing the BEL character (0x07)? It should make a ping!/beep! on the terminal.

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

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