Created
January 2, 2020 20:38
-
-
Save MikaelElkiaer/93a8f8dc7fd9bfc6896aaaaddeb6e441 to your computer and use it in GitHub Desktop.
Get keycode based on keypress
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#/bin/sh | |
xev | awk -F'[ )]+' '/^KeyPress/ { a[NR+2] } NR in a { printf "%-3s %s\n", $5, $8 }'xev | awk -F'[ )]+' '/^KeyPress/ { a[NR+2] } NR in a { printf "%-3s %s\n", $5, $8 }' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment