Skip to content

Instantly share code, notes, and snippets.

@mertcanekiz
Created October 2, 2015 22:20
Show Gist options
  • Save mertcanekiz/814450864cd7ff5fa22c to your computer and use it in GitHub Desktop.
Save mertcanekiz/814450864cd7ff5fa22c to your computer and use it in GitHub Desktop.
Script for enabling/disabling Synaptics Touchpad
#!/bin/bash
tpid=`xinput list | grep SynPS | sed 's/.*id\=\([0-9]\+\).*/\1/g'`
declare -i status
status=`xinput list-props ${tpid} | grep Device\ Enabled | sed -e 's/.*\:[ \t ]\+//g'`
if [ 0 -eq ${status} ] ; then
xinput enable ${tpid}
else
xinput disable ${tpid}
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment