Skip to content

Instantly share code, notes, and snippets.

View ericponce's full-sized avatar

Eric Ponce ericponce

View GitHub Profile
@ericponce
ericponce / tablet-mode
Last active January 29, 2018 18:16
acpid script/trigger for disabling mouse input in tablet mode
# Event file for tablet mode conversions
# Should be placed in /etc/acpi/events
event=tabletmode
action=/etc/acpi/tablet-mode.sh %e
@ericponce
ericponce / rotate.sh
Created January 29, 2018 18:13
Rotated Tablet Mode script for X1 Yoga (2nd Gen), Good for reading and marking PDFs
#!/bin/sh
# screen and input device rotation for e.g. a Thinkpad X1 Yoga
# adopted from by the script from http://ubuntuforums.org/showthread.php?t=996830&p=6274392#post6274392
#
# Usage:
# ./rotate.sh
# will rotate both the screen and input device either to right or normal setting depending on previous state. Additionally:
# * in "right" layout, a on screen keyboard (onboard) is started or stopped in normal mode
# * the touchpad is switched off in "right" mode