docs: document resurrect restore workaround for unix domain mux mode#138
Open
fireboy1919 wants to merge 3 commits into
Open
docs: document resurrect restore workaround for unix domain mux mode#138fireboy1919 wants to merge 3 commits into
fireboy1919 wants to merge 3 commits into
Conversation
added 3 commits
March 12, 2026 10:58
gui-startup is never emitted when default_gui_startup_args = { 'connect', 'unix' },
so resurrect_on_gui_startup silently does nothing in that setup.
Documents the workaround: the mux server writes a timestamped marker file
on first config load (detected via wezterm.GLOBAL + wezterm.gui == nil),
and the GUI reads and deletes it in update-status for a one-shot restore.
The 30-second timestamp guard prevents stale markers from triggering spurious
restores after a crash.
The previous snippet set _startup_restore_done = true immediately when no marker was found, which races with the mux server writing the file. The GUI's first update-status tick often fires before the mux server process has finished its first config load, so the marker hadn't been written yet. Retry for up to 15 seconds before concluding this is a reconnect rather than a cold start. Also add resize_window = false to the restore call to prevent the workspace restore from resizing the window.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
docs: document resurrect restore workaround for unix domain mux mode
gui-startupis never emitted whendefault_gui_startup_args = { "connect", "unix" }even if mux just started,so
resurrect_on_gui_startupsilently does nothing in that setup.Documents the workaround with a complete configuration snippet that users
can copy directly into their
wezterm.lua.