On 2014-01-28 00:50, Patrick Burroughs (Celti) wrote:
On Mon, Jan 27, 2014 at 10:49 PM, Patrick Burroughs (Celti) <celticmadman@gmail.com> wrote:
On Mon, Jan 27, 2014 at 10:02 PM, Daniel Landau <daniel.landau@iki.fi> wrote:
On 27.01.2014 22:04, Patrick Burroughs (Celti) wrote:
Does anyone know of software that offers laptop-mod-tools' configuration to automatically hibernate on a critical battery level?
Does it have to be something other than Gnome?
The suggestion is appreciated, but being a snobby i3 user, I rather despise Gnome, KDE, and other similar weighty environments. I'm making some progress on a udev rule that will do what I want, however; currently I'm testing to see how often my battery emits udev events.
I had a good hunch you wouldn't be satisfied with Gnome :)
And the udev rule works! Now I can completely do away with laptop-mode-tools.
For the curious, I used: SUBSYSTEM=="power_supply", ATTR{status}=="Discharging", ATTR{capacity}=="5", RUN+="/usr/bin/systemctl hybrid-sleep"
This should work for any laptop that emits battery uevents at a reasonable rate; mine didn't seem to at first, but started sending one per 1% drop after it dropped below 15% or so, so if you want to test it you may be waiting a while.
That's cool! Do you think this would fit somewhere in the Wiki or as an AUR package? Are you sure you want hybrid-sleep instead of plain hibernate: both will save your state to disk but with hybrid-sleep you run the risk of running your battery all the way down, which supposedly isn't healthy for the battery (http://www.pcworld.com/article/191574/long_live_your_laptop_battery.html). Daniel