fix(tui): use actual tmux prefix in welcome dialog and status bar#887
Open
redhelix wants to merge 2 commits intonjbrake:mainfrom
Open
fix(tui): use actual tmux prefix in welcome dialog and status bar#887redhelix wants to merge 2 commits intonjbrake:mainfrom
redhelix wants to merge 2 commits intonjbrake:mainfrom
Conversation
…oded Ctrl+b The welcome dialog hardcoded "Ctrl+b" for tmux key hints, which is wrong for users who set a custom prefix (e.g. Ctrl+a). Add tmux_prefix_display() in src/tmux/utils.rs which reads `tmux show-option -gv prefix` at render time and converts the raw tmux format (C-a, M-b, etc.) to a human-readable label. Falls back to "Ctrl+b" if tmux is unavailable. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…Ctrl+b Reads the user's configured tmux prefix via `tmux show-option -gv prefix` and displays it in the session status-left bar, so users with non-default prefixes (e.g. Ctrl+a) see the correct detach hint. 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 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.
Description
AOE hardcodes
Ctrl+bas the tmux prefix in two places:src/tui/dialogs/welcome.rs)src/tmux/status_bar.rs)Users who configure a non-default tmux prefix (e.g.
Ctrl+a, which is common) see misleading detach instructions. This fix reads the actual configured prefix at runtime viatmux show-option -gv prefixand displays it correctly.Changes
src/tmux/utils.rs: Addedtmux_prefix_display()— readstmux show-option -gv prefix, converts tmux notation (C-a,M-b) to human-readable form (Ctrl+a,Alt+b), falls back toCtrl+bif tmux is unavailable.src/tmux/mod.rs: Re-exportstmux_prefix_displayfrom the public API.src/tui/dialogs/welcome.rs: Welcome dialog now callstmux_prefix_display()for all three prefix references (detach key, scroll key, and the note line).src/tmux/status_bar.rs:apply_status_bar()now callstmux_prefix_display()so thestatus-leftinjected into each agent session shows the correct prefix.Root cause
Reported by a user whose tmux prefix is
C-a. The status bar displayedCtrl+b d to detach; pressingCtrl+b ddid nothing; pressing the actual prefixCtrl+a dworked. The mismatch caused confusion about whether AOE itself was broken.PR Type
Checklist
Testing
cargo testpasses (existingtest_enter_submits,test_esc_submits,test_space_submits,test_other_keys_continueinwelcome.rsall green)prefix = C-a: welcome dialog showsCtrl+a then d, status bar showsCtrl+a d to detachtmux_prefix_display()returnsCtrl+bAI Usage
AI Model/Tool used: Claude Sonnet 4.6 (Claude Code)
Any Additional AI Details you'd like to share: Used for implementation and PR writeup; logic and testing verified by the submitting developer.