#!/bin/bash
# My first script
SYNSTATE=$(synclient -l | grep TouchpadOff | awk '{ print $3 }')
# change to the other state
if [ $SYNSTATE -eq 0 ]
then
synclient touchpadoff=1
notify-send "Touchpad" "disabled"
elif [ $SYNSTATE -eq 1 ]
then
synclient touchpadoff=0
notify-send "Touchpad" "enabled"
else
notify-send "Error" "Couldn't get Touchpad status from synclient"
exit 1
fi
exit 0
No comments:
Post a Comment