2024-05-18 04:27:54 +02:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
# Toggle touchpad. Requires xf86-input-synaptics.
|
|
|
|
# by lukesmithxyz, checkout github.com/lukesmithxyz/voidrice
|
|
|
|
|
|
|
|
case "$1" in
|
2025-03-03 04:32:35 +01:00
|
|
|
on) synclient TouchpadOff=0 && notify-send "TouchPad activated." ;;
|
|
|
|
off) synclient TouchpadOff=1 && notify-send "TouchPad deactivated." ;;
|
|
|
|
toggle) (synclient | grep "TouchpadOff.*1") && touchpad on && exit
|
|
|
|
touchpad off ;;
|
2024-05-18 04:27:54 +02:00
|
|
|
*) cat << EOF
|
|
|
|
touchpad: cli script to enable and disable the touchpad.
|
|
|
|
|
|
|
|
Allowed options:
|
2025-03-03 04:32:35 +01:00
|
|
|
on Turn touchpad on
|
|
|
|
off Turn touchpad off
|
|
|
|
toggle Toggle the touchpad on or off
|
2024-05-18 04:27:54 +02:00
|
|
|
all else Print this message
|
|
|
|
|
|
|
|
EOF
|
|
|
|
esac
|