diff options
-rwxr-xr-x | .scripts/toggle_touchpad.sh | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/.scripts/toggle_touchpad.sh b/.scripts/toggle_touchpad.sh index aca2d56..64c018b 100755 --- a/.scripts/toggle_touchpad.sh +++ b/.scripts/toggle_touchpad.sh @@ -1,5 +1,7 @@ #!/bin/bash +exec synclient TouchpadOff=$((1-$(synclient | awk '/TouchpadOff/ { print $3 }'))) + device_id=$(xinput list | sed -n "s/^.*Synaptics.*id=\([^\t]*\).*$/\\1/p") enabled=$(xinput list-props $device_id | sed -n "s/^.*Device Enabled.*\t\(.*\)$/\\1/p") |