Skip to content

Instantly share code, notes, and snippets.

@eladc

eladc/beeper

Last active Dec 17, 2018
Embed
What would you like to do?
beeper
#!/bin/bash
function getID()
{
ID=\$(xinput | grep Touch | sort -g | head -n1 | cut -f2 -d=)
}
xinput test-xi2 --root \$ID \
| grep --line-buffered "EVENT type 22 (RawTouchBegin)" | \
while read line;do getID; paplay /home/kiosk/pop.ogg ;done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment