laptop_hacks
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
laptop_hacks [2017/08/16 19:08] – [Power Disconnect/Connect events] admin | laptop_hacks [2018/10/25 15:52] – [Power Disconnect/Connect events] admin | ||
---|---|---|---|
Line 46: | Line 46: | ||
These events come through DBus, so I run this in my '' | These events come through DBus, so I run this in my '' | ||
- | # if there' | + | # if there' |
upower -e |grep -q battery && { | upower -e |grep -q battery && { | ||
power-monitor & | power-monitor & | ||
Line 57: | Line 57: | ||
| | ||
# needs to run as normal user under X (so that battery-alarm can popup) | # needs to run as normal user under X (so that battery-alarm can popup) | ||
+ | # requires dbus-python | ||
| | ||
import gobject, os, sys | import gobject, os, sys | ||
Line 222: | Line 223: | ||
exit 0 | exit 0 | ||
| | ||
+ | To run stuff on ' | ||
+ | |||
+ | [Unit] | ||
+ | Description=Run on ' | ||
+ | After=suspend.target | ||
+ | | ||
+ | [Service] | ||
+ | User=root | ||
+ | Type=oneshot | ||
+ | ExecStart=/ | ||
+ | | ||
+ | [Install] | ||
+ | WantedBy=suspend.target | ||
+ | |||
+ | and run '' | ||
====Disable nouveau==== | ====Disable nouveau==== | ||
laptop_hacks.txt · Last modified: 2020/02/08 16:41 by admin