This repository was archived by the owner on May 24, 2026. It is now read-only.
feat: add save_non_local_domains opt-in flag for scrollback capture - #146
Open
FelixIsaac wants to merge 1 commit into
Open
feat: add save_non_local_domains opt-in flag for scrollback capture#146FelixIsaac wants to merge 1 commit into
FelixIsaac wants to merge 1 commit into
Conversation
Adds `pub.save_non_local_domains = false` config option to pane_tree. When set to true, scrollback is captured for non-local domains (e.g. WezTerm unix mux server) as well as local panes. Restoration of non-local domain scrollback requires a workaround on the caller side (send_text + temp file) since inject_output is unavailable for non-local domains. Closes MLFlexer#41 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Problem
When using WezTerm with a unix mux domain (
connect unix), pane scrollback is not captured on save becausepane:inject_output()is unavailable for non-local domains. The guard at line 94 (if domain == "local" then) silently skips scrollback for all non-local panes.Fixes #41
Solution
Add an opt-in config flag
pane_tree.save_non_local_domains = false(defaultfalse, no behaviour change). When set totrue, scrollback is captured for all domains.Since
inject_outputis unavailable for non-local domains, callers that enable this flag need their own restore workaround (e.g. writing scrollback to a temp file and replaying viasend_text).Changes
plugin/resurrect/pane_tree.lua: addpub.save_non_local_domains = false; change condition todomain == "local" or pub.save_non_local_domainsTest plan
false): existing behaviour unchanged — non-local panes skip scrollback capturetrue: non-local domain panes havetext/alt_screen_activepopulated in saved state🤖 Generated with Claude Code