Skip to content

feat: Add zellij-backed multiplexer support with tmux fallback - #38

Merged
0dragosh merged 8 commits into
mainfrom
codex/add-support-for-zellij-as-terminal-multiplexer
Mar 18, 2026
Merged

0dragosh merged 8 commits into
mainfrom
codex/add-support-for-zellij-as-terminal-multiplexer

Conversation

@0dragosh

Copy link
Copy Markdown
Owner

Motivation

  • Add first-class support for the Zellij terminal multiplexer so cwt can run sessions under either zellij or tmux and behave the same in both environments.
  • Prefer zellij when it is available while preserving existing tmux behavior and APIs so stored pane/session identifiers and higher-level logic remain compatible.

Description

  • Implemented a multiplexer abstraction in src/tmux/pane.rs with a Multiplexer selector and preferred_multiplexer() that prefers zellij when present and falls back to tmux otherwise.
  • Added zellij helpers (zellij_action, create_zellij_pane, tab name encoding/decoding helpers) and adapted create_pane, focus_pane, kill_pane, pane_exists, pane_current_command, list_panes, pane_pid, and send_keys to dispatch to the appropriate backend.
  • Updated CLI/startup logic in src/main.rs so tmux auto-bootstrap is skipped when zellij is installed, replaced tmux-specific diagnostics with generic multiplexer wording, and extended related unit tests to cover the zellij-available path.
  • Reworded session-launch error messages in src/session/launcher.rs and src/orchestration/dispatch.rs to refer to an active multiplexer (zellij preferred, tmux fallback) without changing higher-level session flow.

Testing

  • Ran cargo fmt which completed successfully.
  • Ran cargo check and cargo clippy --all-targets --all-features which completed without errors.
  • Ran cargo test and all automated tests passed: unit tests 77 passed and integration tests 40 passed (total 117 passed, 0 failed).

Codex Task

@0dragosh 0dragosh changed the title Add zellij-backed multiplexer support with tmux fallback feat: Add zellij-backed multiplexer support with tmux fallback Mar 18, 2026
@0dragosh
0dragosh merged commit bc81ebb into main Mar 18, 2026
3 checks passed
@0dragosh
0dragosh deleted the codex/add-support-for-zellij-as-terminal-multiplexer branch March 18, 2026 15:47
@github-actions github-actions Bot mentioned this pull request Mar 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant