blob: 48ac5f514dd9394050cfe109acaf4bd24dc428be (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
[Unit]
Description=Configure device events for linux-macbook
ConditionPathExists=/proc/acpi/wakeup
[Service]
Type=oneshot
ExecStart=/bin/sh -c "awk '$1 !~ /^LID/ && $3 ~ /enabled/ {print $1}' /proc/acpi/wakeup | xargs -I{} echo '{}' > /proc/acpi/wakeup"
ExecStart=/bin/sh -c "awk '$1 ~ /^LID/ && $3 ~ /disabled/ {print $1}' /proc/acpi/wakeup | xargs -I{} echo '{}' > /proc/acpi/wakeup"
RemainAfterExit=yes
TimeoutSec=0
[Install]
WantedBy=multi-user.target
|