5 lines
780 B
Plaintext
5 lines
780 B
Plaintext
timeout 280 '[ "$(cat /sys/class/power_supply/AC/online 2>/dev/null)" = "0" ] && notify-send "Suspend in 20s" "Produce some acivity or run inhibit to cancel" -a "idle" -t 20000 -h string:x-canonical-private-synchronous:inactivity' resume '[ "$(cat /sys/class/power_supply/AC/online 2>/dev/null)" = "0" ] && notify-send "" -a "idle" -t 1 -h string:x-canonical-private-synchronous:inactivity'
|
|
timeout 300 '[ "$(cat /sys/class/power_supply/AC/online 2>/dev/null)" = "0" ] && systemctl suspend'
|
|
timeout 1780 'notify-send "Suspend in 20s" "Produce some acivity or run inhibit to cancel" -a "idle" -t 20000 -h string:x-canonical-private-synchronous:inactivity' resume 'notify-send "" -a "idle" -t 1 -h string:x-canonical-private-synchronous:inactivity'
|
|
timeout 1800 'systemctl suspend'
|