Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/bash
- # init
- grep -q closed /proc/acpi/button/lid/LID/state
- if [ $? = 0 ]; then
- grep -q 0 /sys/class/power_supply/AC/online
- if [ $? = 0 ]; then
- sudo pm-suspend
- fi
- fi
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement