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/sh | |
DEVICE_ID=`xinput list | grep "Logitech Gaming Mouse G300" | grep keyboard | sed 's/.*id=\([0-9]*\).*/\1/'` | |
if xinput -list-props $DEVICE_ID | grep "Device Enabled" | grep "1$" > /dev/null | |
then | |
xinput set-int-prop $DEVICE_ID "Device Enabled" 8 0 | |
fi |