summary refs log tree commit diff stats
path: root/bin/touchpad_enable_tap.sh
diff options
context:
space:
mode:
authorBenjamin Morrison <ben@gbmor.org>2022-01-25 22:30:22 -0500
committerBenjamin Morrison <ben@gbmor.org>2022-01-25 22:30:22 -0500
commit6c20915867378b468b8847d34a28f6fdb24877e5 (patch)
treeaade14f745bd9bc4d4a7bfa3758d2576b7c2a163 /bin/touchpad_enable_tap.sh
parent8c19e3556d4ac88a41495a101ba5d7a5558145bd (diff)
downloaddogfiles-6c20915867378b468b8847d34a28f6fdb24877e5.tar.gz
script to enable touchpad tapping / tap-to-click
Diffstat (limited to 'bin/touchpad_enable_tap.sh')
-rwxr-xr-xbin/touchpad_enable_tap.sh16
1 files changed, 16 insertions, 0 deletions
diff --git a/bin/touchpad_enable_tap.sh b/bin/touchpad_enable_tap.sh
new file mode 100755
index 0000000..c57a4aa
--- /dev/null
+++ b/bin/touchpad_enable_tap.sh
@@ -0,0 +1,16 @@
+#!/bin/sh
+set -eu
+
+# This enables tapping, like tap-to-click, on the Thinkpad T14s Gen2 AMD.
+# The touchpad ID changes between reboots sometimes.
+#
+# We need property 318, "Tapping Enabled".
+# Available properties viewable with:
+#       xinput list-props $TOUCHPAD_ID
+#
+# Requires:
+#       xinput, libinput
+
+TOUCHPAD_ID="$(xinput | grep Touchpad | awk '{print $6}' | cut -d'=' -f2)"
+
+/usr/bin/xinput set-prop "$TOUCHPAD_ID" 318 1