Skip to content

Instantly share code, notes, and snippets.

@joanrieu
Created February 15, 2014 03:38
Show Gist options
  • Save joanrieu/9014225 to your computer and use it in GitHub Desktop.
Save joanrieu/9014225 to your computer and use it in GitHub Desktop.
Wacom tablet settings for xinput
#!/bin/bash
function list {
xinput list --name-only | grep Wacom
}
function create {
xinput create-master 'Wacom'
list | xargs -i{} xinput reattach {} 'Wacom pointer'
list | grep Pen | xargs -i{} xinput map-to-output {} 'DVI-0'
list | grep touch | xargs -i{} xinput disable {}
}
function remove {
xinput remove-master 'Wacom pointer'
}
if xinput list --name-only | grep -q 'Wacom pointer' ; then
remove
else
create
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment