diff options
Diffstat (limited to 'src/udev/generate-keyboard-keys-gperf.sh')
-rwxr-xr-x | src/udev/generate-keyboard-keys-gperf.sh | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/udev/generate-keyboard-keys-gperf.sh b/src/udev/generate-keyboard-keys-gperf.sh new file mode 100755 index 0000000000..36ce0bd6cc --- /dev/null +++ b/src/udev/generate-keyboard-keys-gperf.sh @@ -0,0 +1,9 @@ +#!/bin/sh -eu +awk ' BEGIN { + print "struct key_name { const char* name; unsigned short id; };" + print "%null-strings" + print "%%" + } + + /^KEY_/ { print tolower(substr($1 ,5)) ", " $1 } +' < "$1" |