From 45d98e81d97ad7e5f45e6b210b009bf7da685595 Mon Sep 17 00:00:00 2001 From: Adam Goldsmith Date: Mon, 2 Nov 2020 01:03:45 -0500 Subject: [PATCH] Add "reboot to windows" option to lock script --- .config/i3/lock.sh | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/.config/i3/lock.sh b/.config/i3/lock.sh index 44eaffc..0846f5a 100755 --- a/.config/i3/lock.sh +++ b/.config/i3/lock.sh @@ -34,14 +34,17 @@ case "$1" in reboot) systemctl reboot ;; + "reboot to Windows") + sudo refind-next-boot 'Microsoft' && systemctl reboot + ;; shutdown) systemctl poweroff ;; pick) - $0 $(echo -e "lock\nlogout\nsuspend\nhibernate\nreboot\nshutdown" | rofi -dmenu -i) + $0 "$(echo -e 'lock\nlogout\nsuspend\nhibernate\nreboot\nreboot to Windows\nshutdown' | rofi -dmenu -i)" ;; *) - echo "Usage: $0 {lock|logout|suspend|hibernate|reboot|shutdown|pick}" + echo "Usage: $0 {lock|logout|suspend|hibernate|reboot|reboot to Windows|shutdown|pick}" exit 2 ;; esac