Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
Toggle touchpad activation with gsettings.
#!/bin/bash
#
# touchpad-toggle: Toggle touchpad activation with gsettings.
# Copyright (C) 2015 Guillaume Kulakowski <guillaume@kulakowski.fr>
# Version 1.0
#
SCHEMA="org.gnome.desktop.peripherals.touchpad"
KEY="send-events"
STATUS=$(gsettings get ${SCHEMA} ${KEY})
if [ "${STATUS}" == "'enabled'" ]; then
gsettings set ${SCHEMA} ${KEY} 'disabled'
else
gsettings set ${SCHEMA} ${KEY} 'enabled'
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment