I am using FreeBSD 12.1 a lot more these days and I find the console, sans gui, to be a more and more comfortable place to work from. When I want to multitask, I tend to startx with twm. My question is, how can I get the system to sleep/hibernate automatically when the battery is low, if I'm not using a desktop environment? I keep forgetting to shut down my laptop after using it and setting it aside, only to come back to it and it having precipitously shut down, requiring a restart after attaching power. It's a Thinkpad T430 and ACPI works (hit the power button for a sec and it sends a shutdown signal).
Ideally, this would be a background task that monitors the battery and when it hits 10% sleeps or hibernates or warns then sleeps... It would work even when only logged into the console, but if it worked in twm, that'd be ok, too.
Ideally, this would be a background task that monitors the battery and when it hits 10% sleeps or hibernates or warns then sleeps... It would work even when only logged into the console, but if it worked in twm, that'd be ok, too.