summaryrefslogtreecommitdiff
path: root/src/main/gen-token-header.sh
diff options
context:
space:
mode:
authorMathias Preiner <mathias.preiner@gmail.com>2018-08-14 17:43:17 -0700
committerMathias Preiner <mathias.preiner@gmail.com>2018-09-22 16:30:59 -0700
commit52b9d01f4c3cc0b34daa4759e1004fc315f3f30e (patch)
tree7064ba2c9c80642cc39cd8e7fa51a020810733f1 /src/main/gen-token-header.sh
parent2c7e0aab31d4f8b2f58da00e67e2e7b5edfb166d (diff)
cmake: Generate token headers.
Diffstat (limited to 'src/main/gen-token-header.sh')
-rw-r--r--src/main/gen-token-header.sh5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/main/gen-token-header.sh b/src/main/gen-token-header.sh
new file mode 100644
index 000000000..86e30ae42
--- /dev/null
+++ b/src/main/gen-token-header.sh
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+grep "'[a-zA-Z][a-zA-Z0-9_-][a-zA-Z0-9_-]*'" "$1" | \
+ sed 's/.*'\''\([a-zA-Z0-9_-]*\)'\''.*/"\1",/' | \
+ sort -u > "$2"
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback