Comment 7 for bug 1461386

Revision history for this message
Michele Kipiel (michele-kipiel) wrote :

Update: I seem to have solved the problem tweaking the udev commands as follows:

SUBSYSTEM=="power_supply", ATTR{online}=="0", RUN+="/usr/sbin/pm-powersave true"
SUBSYSTEM=="power_supply", ATTR{online}=="1", RUN+="/usr/sbin/pm-powersave true"

this way pm-powersave is executed every time a power source change happens, allowing the if/else statement i put in the custom script to take care of the rest.

I don't know whether this is a long-term solution, but it seems to be working so far.