Repository navigation
feat: add an opt-in headless WezTerm backend - #289
Draft
cpendery (cpendery) wants to merge 1 commit into
Draft
cpendery (cpendery) wants to merge 1 commit into
cpendery (cpendery) wants to merge 1 commit into
Conversation
This branch has not been deployed
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
Add an opt-in
weztermbackend using WezTerm's non-UI Rust VT crates, pinned toe68a8ec27727fbbda15e07f0a0737cd5e16481f6. No WezTerm application, window, GPU renderer, multiplexer, or WezTerm-managed PTY is involved.Emulator.The core's writer is asynchronous. The adapter fences its FIFO through the supplied capture writer before draining replies or returning native key encodings. Fence bytes are removed before anything is forwarded to the PTY; regression coverage includes split escape sequences, bracketed paste, and previously queued terminal replies.
Native differences are preserved and explicitly asserted in conformance coverage: ST-only color replies, ignored OSC 52 read queries, ignored title-stack operations, mutually exclusive bold/dim intensity, bare palette resets that also reset dynamic colors, and wide-glyph overflow at the right margin. The latter is a native edge case, not normalized to another emulator's wrapping behavior.
Draft blocker
Keep this as a draft. The pinned upstream
termwiz0.24.0 and split VT crates are not all published to crates.io.cargo package --locked --allow-dirty -p tui-test-rs --no-verifycurrently fails on the unavailable registry version oftermwiz. This affects publishing the crate even when the optional feature is disabled. Upstream publication or an agreed vendoring/distribution approach is required before merging this into a releasable version.Source builds and custom native libraries work. Documentation makes the source-build requirement and native behavior differences explicit.
Validation
Performed on Windows:
Backend::Wezterm.cargo clippy --locked --workspace --all-targets --all-features -- -D warnings.tui-test-ffiwith--features wezterm; Python, JavaScript, and Go in-process smoke runs each selected the backend, launched a child, and observed native bold/dim behavior through a style locator.Linux and macOS execution is covered by the added CI steps, not claimed as locally exercised.