Fix #361: make detach key configurable via hotkeys#365
Merged
asheshgoplani merged 1 commit intomainfrom Mar 18, 2026
Merged
Conversation
Add "detach" action to the hotkey system (default: ctrl+q) so users whose terminals intercept Ctrl+Q (XON/XOFF flow control, Zellij, etc.) can remap to a key that passes through. - Generalize IndexCtrlQ into IndexDetachKey that works with any control-key byte and its xterm/kitty escape-sequence encodings - Keep IndexCtrlQ as a backward-compatible wrapper - Thread the configured detach byte through Attach/AttachWindow (variadic, backward compatible) from TUI and CLI callers - Show the configured key label in `session attach` usage text Committed by Ashesh Goplani
|
Hi @asheshgoplani 👋 I really like your product and appreciate you guys being so responsive to fix this. Keep up the wonderful work, Valentin. |
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
detachaction to the existing[hotkeys]config system, defaulting toctrl+qIndexCtrlQintoIndexDetachKeythat works with any control-key byte (raw + xterm modifyOtherKeys + kitty CSI u encodings)Attach/AttachWindowfrom TUI and CLI callers (variadic parameter, fully backward compatible)Users whose terminals intercept Ctrl+Q (XON/XOFF flow control in iTerm2, Zellij multiplexer, etc.) can now remap to any
ctrl+key in~/.agent-deck/config.toml:Fixes #361
Test plan
IndexCtrlQtests pass (wrapper overIndexDetachKey)TestIndexDetachKeywith 16 cases (different keys, encodings, prefixes)TestDetachByteFromBindingwith 14 casesTestDetachByteLabelwith 10 casesTestResolvedDetachBytewith 5 casesgolangci-lint runpassesgo test -race ./...passes