mirror of https://github.com/sgoudham/dotfiles.git
feat: script to toggle keyboard backlighting
parent
cd443f23e6
commit
f054a7b500
@ -0,0 +1,15 @@
|
||||
#!/bin/bash
|
||||
|
||||
OFF=0
|
||||
ON=2
|
||||
PATH=/sys/devices/platform/dell-laptop/leds/dell::kbd_backlight/brightness
|
||||
PREVIOUS_SETTING=$(< $PATH)
|
||||
|
||||
if [[ $PREVIOUS_SETTING -eq $OFF ]]
|
||||
then
|
||||
echo $ON > $PATH
|
||||
echo "Keyboard Backlighting: ON"
|
||||
else
|
||||
echo $OFF > $PATH
|
||||
echo "Keyboard Backlighting: OFF"
|
||||
fi
|
Loading…
Reference in New Issue