Files
dots/.config/polybar/touchpad-indicator.sh
2018-07-16 21:22:48 +02:00

12 lines
308 B
Bash
Executable File

#!/bin/sh
touchpad_status=$(synclient | grep Touchpad | tail -c 2 | head -c 1 2> /dev/null)
if [ "$touchpad_status" = "1" ]; then
echo "%{A1:synclient TouchpadOff=0:}%{F#404040}ﳶ%{F-} %{A}"
elif [ "$touchpad_status" = "0" ]; then
echo "%{A1:synclient TouchpadOff=1:}ﳶ %{A}"
else
echo ""
fi