Skip to content

Commit a996438

Browse files
committed
Add explicit reboot + shutdown scripts that close all windows first (and allow a second to save state)
1 parent 9524259 commit a996438

File tree

3 files changed

+14
-2
lines changed

3 files changed

+14
-2
lines changed

bin/omarchy-cmd-reboot

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
#!/bin/bash
2+
3+
omarchy-state clear re*-required
4+
omarchy-hyprland-window-close-all
5+
sleep 1 # Allow apps like Chrome to shutdown correctly
6+
systemctl reboot --no-wall

bin/omarchy-cmd-shutdown

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
#!/bin/bash
2+
3+
omarchy-state clear re*-required
4+
omarchy-hyprland-window-close-all
5+
sleep 1 # Allow apps like Chrome to shutdown correctly
6+
systemctl poweroff --no-wall

bin/omarchy-menu

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -438,8 +438,8 @@ show_system_menu() {
438438
*Lock*) omarchy-lock-screen ;;
439439
*Screensaver*) omarchy-launch-screensaver force ;;
440440
*Suspend*) systemctl suspend ;;
441-
*Restart*) omarchy-state clear re*-required && systemctl reboot --no-wall ;;
442-
*Shutdown*) omarchy-state clear re*-required && systemctl poweroff --no-wall ;;
441+
*Restart*) omarchy-cmd-reboot ;;
442+
*Shutdown*) omarchy-cmd-shutdown ;;
443443
*) back_to show_main_menu ;;
444444
esac
445445
}

0 commit comments

Comments
 (0)