nsbin/acpi-lid-close

9 lines
184 B
Text
Raw Normal View History

#!/bin/sh
if grep -q closed /proc/acpi/button/lid/*/state; then
sleep 3
su nico -c "DISPLAY=:0.0 xset dpms force off"
else
su nico -c "DISPLAY=:0.0 xset dpms force on"
fi