If you want to make some kind of screencast that features keyboard typing sounds, this might come in handy. Get the script, run linux-typewriter.rb and pump up your volume.
This is totally hacked-away, but it works for me. Your mileage may vary, though.
-
Python, Ruby, Rubygems
-
python-xlib
(On Debian-based, install withsudo apt-get install python-xlib)
-
aplay command line player, but you really can dump in anything you want, see
linux-typewriter.rb
-
sinatra
(sudo gem install sinatra)
Simple: The aplay
command is too slow when used directly from keypress.py
, locking the process for a while. I am no python genius and have no idea how to establish a thread, and I do not care. It now makes a webrequest to the running sinatra app, which launches aplay in a separate thread, thus not locking the keypress listener anymore.
keypress.py by Sayan “Riju” Chakrabarti, Released under WTFPL Version 2 rants.sayanriju.co.cc/script-to-make-tick-tick-sound-on-keypress
-
Modifications by Christoph Olszowka
Keypress sounds extracted from ‘keyboard-typing’ by Anton at Freesound, www.freesound.org/samplesViewSingle.php?id=137