From ffd3c79ab27851d5ffbc9902e682ad594b2260b6 Mon Sep 17 00:00:00 2001 From: David Heinemeier Hansson Date: Thu, 23 Jul 2026 19:25:11 -0700 Subject: [PATCH] Resend pending invitations after restarting the shell MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Restarting the shell kills its notification server, and a pending invitation's notify-send waiter then hangs forever: the dying server never emits NotificationClosed. So a still-running omarchy-*-invitation unit means an unanswered invitation — re-run it once the new shell is up so its toast reappears. Co-Authored-By: Claude Fable 5 --- bin/omarchy-restart-shell | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/bin/omarchy-restart-shell b/bin/omarchy-restart-shell index ee07d931..9ee803e8 100755 --- a/bin/omarchy-restart-shell +++ b/bin/omarchy-restart-shell @@ -28,7 +28,16 @@ while timeout 5 quickshell kill -p "$CONFIG_DIR" --any-display >/dev/null 2>&1; hyprctl dispatch 'hl.dsp.exec_cmd("quickshell -n -p $OMARCHY_PATH/shell")' >/dev/null for (( attempt = 0; attempt < 20; attempt++ )); do - OMARCHY_SHELL_IPC_TIMEOUT=0.5s omarchy-shell shell ping >/dev/null 2>&1 && exit 0 + if OMARCHY_SHELL_IPC_TIMEOUT=0.5s omarchy-shell shell ping >/dev/null 2>&1; then + # Invitation toasts (like Voxtype/fingerprint setup) die with the old + # shell, and their notify-send waiters hang forever: the dying server + # never emits NotificationClosed. A still-running omarchy-*-invitation + # unit is therefore an unanswered invitation — re-run it so its toast + # reappears on the new shell. Answered invitations have already exited + # and been collected, so the glob no longer matches them. + systemctl --user try-restart 'omarchy-*-invitation.service' 2>/dev/null || true + exit 0 + fi sleep 0.1 done