feat(app): send Enter after send-selection paste#10
Merged
Conversation
Add the noa-specific boolean key send-selection-send-enter (default off). When enabled, the send-selection picker follows the paste into the target pane with an Enter so the pasted text is submitted immediately. The Enter is appended to the encoded paste outside the bracketed-paste wrapper and written as one queue element, so a backpressured input queue admits or drops the pair atomically (a lone Enter after a dropped paste would execute the stale prompt line). It is encoded via the real key encoder under the target pane's Kitty keyboard flags (CSI 13 u under report-all-keys, legacy CR otherwise), deferred behind the clipboard-paste-protection confirm dialog together with the paste, and skipped when nothing was pasted. Normal cmd+v paste behavior is unchanged. The key is also editable from the Settings overlay as a new "Send Selection Enter" row (bool toggle, on-save, mirrored into the running config on commit and on undo, same shape as Confirm Quit).
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
Adds the noa-specific config key
send-selection-send-enter(defaultfalse). When enabled, the Send Selection to Pane picker follows the paste into the target pane with an Enter, so the sent selection is submitted immediately.CSI 13 uunder report-all-keys, legacy CR otherwise), so Kitty-protocol TUIs recognize it.clipboard-paste-protectionraises the confirm dialog, the Enter is deferred with the paste and sent only on confirm.Test plan
cargo test -p noa-app(811) /cargo test -p noa-config(167) all green;cargo clippy --workspaceclean (full-workspace ipc/pty suites verified unsandboxed)encode_enter_keyvs Kitty flags, settings-row toggle→commit key/value proof, revert/undo config mirroring