Skip to content

Instantly share code, notes, and snippets.

@llaumgui
Created October 29, 2015 20:25
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save llaumgui/16e581545399f2c057ab to your computer and use it in GitHub Desktop.
Save llaumgui/16e581545399f2c057ab to your computer and use it in GitHub Desktop.
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