Sleep less when power on

This commit is contained in:
Ryan 2024-02-27 18:46:56 +08:00
parent e0d7aaaaab
commit 93edaee6a1
1 changed files with 5 additions and 6 deletions

View File

@ -14,12 +14,11 @@ choice=$(printf "%s\n" "${choices[@]}" | fuzzel -d --prompt "󰚥: ")
if test "$choice" = lock ; then
# sleep less when power on
# if acpi -a | grep -q on; then
# sleep_time=3600
# else
# sleep_time=10
# fi
sleep_time=10
if acpi -a | grep -q on; then
sleep_time=3600
else
sleep_time=10
fi
sleep 0.3
bright=`light`