Dear #LazyFedi
I run a "minimal" #Debian system based on #i3wm, but I'd like my laptop to suspend or shutdown when the battery power gets too low, to avoid running the battery right to zero. What is a reasonable to do this? #upower seems like it might be part of the answer, but it seems like it is mainly glue to provide non-root users the ability to suspend etc...
@bremner laptop-mode-tools ?
@bremner I think there is an 'i3-msg' way to do this.
@bremner i have a similar need. i don't really need the laptop to suspend or shutdown when the laptop is online, typically i'm at the desk and will notice it's about to run out.... what I want is something that *wakes up* while in suspend to do an orderly shutdown instead of just zapping out of existence when running out of power in suspend
@bremner I'm using fdpowermon (and my config is partially in the package as an example, or available on request :))
@bremner previously did this in `/etc/udev/rules.d/99-lowbat.rules`
```
SUBSYSTEM=="power_supply", ATTR{status}=="Discharging", ATTR{capacity}=="[0-5]", RUN+="/bin/systemctl hibernate"
```
Which would hibernate whenever the battery level was 5% or less