aboutsummaryrefslogtreecommitdiff
path: root/.local
diff options
context:
space:
mode:
Diffstat (limited to '.local')
-rwxr-xr-x.local/share/bin/wacomtouch14
1 files changed, 14 insertions, 0 deletions
diff --git a/.local/share/bin/wacomtouch b/.local/share/bin/wacomtouch
new file mode 100755
index 0000000..6c1e51a
--- /dev/null
+++ b/.local/share/bin/wacomtouch
@@ -0,0 +1,14 @@
+#!/bin/sh
+# print if wacom tablet has touch on or off
+bye() {
+ echo $1
+ exit
+}
+
+[ ! -e /dev/input/by-id/usb-Wacom_Co._Ltd._Intuos_PTS-if01-event-mouse ] && bye
+
+if evtest --query /dev/input/by-id/usb-Wacom_Co._Ltd._Intuos_PTS-if01-event-mouse EV_SW SW_MUTE_DEVICE; then
+ bye "touch on"
+else
+ bye "touch off"
+fi