feat(scripts): make toggle-keyboard-backlights more robust

chezmoi
sgoudham 2 years ago
parent 68904df6c1
commit a6c1e576dd
Signed by: hammy
GPG Key ID: 44E818FD5457EEA4

@ -8,8 +8,16 @@ PREVIOUS_SETTING=$(< $KEYBOARD_PATH)
if [[ $PREVIOUS_SETTING -eq $OFF ]]
then
echo $ON > $KEYBOARD_PATH
if [[ $? -ne 0 ]]; then
echo "ERROR: Could Not Update Settings"
exit 1
fi
echo "Keyboard Backlighting: ON"
else
echo $OFF > $KEYBOARD_PATH
if [[ $? -ne 0 ]]; then
echo "ERROR: Could Not Update Settings"
exit 1
fi
echo "Keyboard Backlighting: OFF"
fi

Loading…
Cancel
Save