summaryrefslogtreecommitdiff
path: root/keyboards/ergodox/keymaps/algernon/tools/layer-notify
diff options
context:
space:
mode:
authorChris Browne <cbbrowne@hpaq.int.linuxdatabases.info>2016-10-10 17:18:15 -0400
committerChris Browne <cbbrowne@hpaq.int.linuxdatabases.info>2016-10-10 17:18:15 -0400
commit4b682ea63e2b3dd0bc1132917be7985ce0da57a6 (patch)
tree6d79874c5542148c27907511ecdb2e9e5e12b24b /keyboards/ergodox/keymaps/algernon/tools/layer-notify
parent04759d63ef9b520fc41d76de64bb65198448fc1c (diff)
parenta9df99b81c787862dc3fa11bd854fe39e704da81 (diff)
Merge branch 'master' of github.com:cbbrowne/qmk_firmware
Diffstat (limited to 'keyboards/ergodox/keymaps/algernon/tools/layer-notify')
-rwxr-xr-xkeyboards/ergodox/keymaps/algernon/tools/layer-notify12
1 files changed, 12 insertions, 0 deletions
diff --git a/keyboards/ergodox/keymaps/algernon/tools/layer-notify b/keyboards/ergodox/keymaps/algernon/tools/layer-notify
new file mode 100755
index 0000000000..627c2861ef
--- /dev/null
+++ b/keyboards/ergodox/keymaps/algernon/tools/layer-notify
@@ -0,0 +1,12 @@
+#!/bin/sh
+HL="${HID_LISTEN:-$HOME/src/ext/hid_listen/hid_listen}"
+
+sudo "${HL}" | grep --line-buffered LAYER: | \
+(while read line; do
+ case $line in
+ LAYER:*)
+ layer="$(echo $(echo $line | cut -d: -f2-))"
+ notify-send -i mark-location-symbolic "Switched to layer: $layer"
+ ;;
+ esac
+ done)