Created
June 19, 2011 18:59
-
-
Save RJHsiao/1034606 to your computer and use it in GitHub Desktop.
Shell script for set TrackPoint's Speed & Sensitivity with login
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /bin/bash | |
if [ ! -w /sys/devices/platform/i8042/serio1/serio2/sensitivity -o ! -w /sys/devices/platform/i8042/serio1/serio2/speed ];then | |
gksu --description "Get write permission to set TrackPoint's Speed & Sensitivity" chmod g+w /sys/devices/platform/i8042/serio1/serio2/sensitivity /sys/devices/platform/i8042/serio1/serio2/speed | |
fi | |
if [ `cat /sys/devices/platform/i8042/serio1/serio2/sensitivity` -ne 255 -o `cat /sys/devices/platform/i8042/serio1/serio2/speed` -ne 120 ]; then | |
echo -n 255 > /sys/devices/platform/i8042/serio1/serio2/sensitivity | |
echo -n 120 > /sys/devices/platform/i8042/serio1/serio2/speed | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment