dotfiles/unprocessed/config/polybar/bbswitch
Geoffrey Frogeye ee178b7d57
nix: Make nix the root
Which means now I'll have to think about real prefixes in commit names.
2023-11-26 23:58:22 +01:00

19 lines
288 B
Bash
Executable file

#!/usr/bin/env bash
if [ -f /proc/acpi/bbswitch ]
then
echo -n 
state="$(grep -o '\w\+$' /proc/acpi/bbswitch)"
if [ "$state" == "ON" ]
then
echo ""
elif [ "$state" == "OFF" ]
then
echo ""
else
echo "?"
fi
else
echo
fi