lowbat brightness adjust
All checks were successful
Activate Homelab Configuration / rebuild (push) Successful in 18s
All checks were successful
Activate Homelab Configuration / rebuild (push) Successful in 18s
This commit is contained in:
parent
d4b19a279e
commit
c3d19551ee
1 changed files with 1 additions and 1 deletions
|
|
@ -19,7 +19,7 @@
|
|||
echo "`date` battery status:$BAT_STA percentage:$BAT_PCT"
|
||||
export DISPLAY=:0
|
||||
export DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/$(id -u)/bus
|
||||
test $BAT_PCT -le 30 && test $BAT_PCT -gt 15 && test $BAT_STA = "Discharging" && ${pkgs.libnotify}/bin/notify-send "Low Battery" "Battery remaining: $BAT_PCT%."
|
||||
test $BAT_PCT -le 30 && test $BAT_PCT -gt 15 && test $BAT_STA = "Discharging" && ${pkgs.libnotify}/bin/notify-send "Low Battery" "Battery remaining: $BAT_PCT%." && brightnessctl s 30%
|
||||
test $BAT_PCT -le 15 && test $BAT_STA = "Discharging" && ${pkgs.libnotify}/bin/notify-send -u critical "Low Battery" "Shutdown at 10%."
|
||||
''} > /tmp/cron.batt.log 2>&1"
|
||||
];
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue