Last active
November 9, 2022 19:03
-
-
Save cmndrsp0ck/08f88b8bb0da278a363d095ea335f384 to your computer and use it in GitHub Desktop.
using this to toggle touchpad with a keyboard shortcut
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -e | |
trkpad=$(synclient | grep -i 'touchpadoff' | awk '{print $(NF)}') | |
if (( trkpad == 0 )); then | |
synclient TouchpadOff=1 | |
notify-send -t 1500 'Touchpad Disabled' | |
else | |
synclient TouchpadOff=0 | |
notify-send -t 1500 'Touchpad Enabled' | |
fi | |
unset trkpad |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment