From 977d8824da394f9830f2aa1093b359bc5cf48537 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Sat, 15 Jan 2011 00:42:09 +0100 Subject: Add lskeys helper script --- scripts/lskeys.pl | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100755 scripts/lskeys.pl diff --git a/scripts/lskeys.pl b/scripts/lskeys.pl new file mode 100755 index 0000000..530e38d --- /dev/null +++ b/scripts/lskeys.pl @@ -0,0 +1,20 @@ +#!/usr/bin/env perl +use strict; +use warnings; +use 5.010; + +use autodie; + +my @keys; + +open(my $fh, '<', 'src/keyevents.c'); +while (my $line = <$fh>) { + chomp($line); + if ($line =~ qr{ + if \s \( \! strcmp \( action , \s " (? [^"]+ ) " \)\) }x) { + push(@keys, $+{key}); + } +} +close($fh); + +say join("\n", sort @keys); -- cgit v1.2.3