From 5925500930ddb2465b4b0a0c61f1bd2f6e0affa0 Mon Sep 17 00:00:00 2001 From: Marty Oehme Date: Fri, 19 Feb 2021 10:39:55 +0100 Subject: [PATCH] rofi: Switch sleep action to hibernate mode Switched out the suspend action from the rofi powermenu (called through super + backspace in current sxhkd setup) to instead call hibernate. This needs a correctly set up system to engage hibernate - all the documentation necessary can be found at https://wiki.archlinux.org/index.php/Power_management/Suspend_and_hibernate Generally, needs a swap file and resume (i.e. hibernation) correctly set up in both the kernel parameters and the initramfs. On this machine (laptop), the way things work now is that simply closing the lid leads to the default sleep action (suspend), and invoking the manual rofi-powermenu way will instead completely hibernate the system, leading to less power usage but taking a little longer to switch off and restore. --- rofi/.config/rofi/modes/powermenu | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rofi/.config/rofi/modes/powermenu b/rofi/.config/rofi/modes/powermenu index a3a076a..9bac8fb 100755 --- a/rofi/.config/rofi/modes/powermenu +++ b/rofi/.config/rofi/modes/powermenu @@ -58,7 +58,7 @@ case $(echo "$*" | grep -a -o -e "Shutdown" -e "Reboot" -e "Lockscreen" -e "Logo "Suspend") if [ -n "$ROFI_POWERMENU_SUSPEND_CMD" ]; then eval "$ROFI_POWERMENU_SUSPEND_CMD"; else lockscreen rofi /dev/null 2>/dev/null & - systemctl suspend + systemctl hibernate fi ;; esac