diff --git a/desktop/.config/river/init b/desktop/.config/river/init index 151c69d..7a95637 100755 --- a/desktop/.config/river/init +++ b/desktop/.config/river/init @@ -5,7 +5,7 @@ modemod="Mod1" term=${TERMINAL:-foot} time_to_lockscreen=300 time_to_screendim=600 -time_to_suspend=1200 +time_to_suspend=900 ## OPTIONS riverctl spawn "dbus-update-activation-environment SEATD_SOCK DISPLAY WAYLAND_DISPLAY XDG_CURRENT_DESKTOP=river" @@ -268,13 +268,13 @@ unset loc # start screen idle locking/dimming/sleep tool killall swayidle riverctl spawn "swayidle \ - timeout ${time_to_lockscreen} 'pidof waylock || lockscreen' \ - timeout ${time_to_screendim} 'wlopm --off \"*\"' \ - timeout ${time_to_suspend} 'systemctl suspend-then-hibernate' \ - resume 'wlopm --on \"*\"' \ - after-resume 'wlopm --on \"*\"' \ - before-sleep 'pidof waylock || lockscreen' &" - + timeout ${time_to_suspend} \"systemctl suspend-then-hibernate\" \ + timeout ${time_to_suspend} \"[ $(cat /sys/class/power_supply/AC/online) -eq 0 ] && systemctl suspend-then-hibernate\" + timeout ${time_to_screendim} \"wlopm --off '*'\" \ + resume \"wlopm --on '*'\" \ + timeout ${time_to_lockscreen} \"pidof waylock || lockscreen\" \ + after-resume \"wlopm --on '*'\" \ + before-sleep \"pidof waylock || lockscreen\" &" killall clipman riverctl spawn "wl-paste -t text --watch clipman store" # bash ~/.config/bin/gtktheme # setting our gtk variables