License Public Domain
Lines 1
system bell (1)
Viewable by Everyone
Editable by All Siafoo Users
Siafoo is here to make coding less frustrating and to save you time. Join Siafoo Now or Learn More

Ring the Bell Atom Feed 0

In Brief How to ring the bell from the terminal.... more
# 's
1echo $'\a'

How to ring the bell from the terminal.

Printing "\a" from bash, Python, and most other languages will ring the bell. It's almost trivial, but a good (if annoying) way to communicate with the user.

For example, when developing Siafoo we run unittests occasionally, these could take a while or crash right away, and I don't want to sit and stare at them:

# 's
1nosetests -x [some other options]; echo $'\a'

Now I can tell audibly when the tests are done.... granted I can also tell when my laptop stops sounding like a jet engine, but that's a bit more delayed...