cachyos: soft-handoff on return-to-desktop instead of reboot

This commit is contained in:
mia26MAjFm
2026-07-04 23:07:26 -04:00
parent 74f978b1bb
commit 34fa9da3f1

12
distros/cachyos/files/steamos-session-select Normal file → Executable file
View File

@@ -73,6 +73,14 @@ case "$session" in
fi fi
;; ;;
desktop|plasma|plasma-wayland|plasmax11) desktop|plasma|plasma-wayland|plasmax11)
exec sudo systemctl reboot # Soft handoff: terminate the current session; agetty respawns
# tty1 and profile.d reads next-session=plasma. Avoids the reboot
# tax on return-to-desktop.
if [[ -n "${XDG_SESSION_ID:-}" ]]; then
loginctl terminate-session "$XDG_SESSION_ID"
else
pkill -u steam gamescope-session-ps5 || true
pkill -u steam gamescope || true
fi
;; ;;
esac esac