aboutsummaryrefslogtreecommitdiff
path: root/tests/test-vterm-copy-mode-cursor.el
diff options
context:
space:
mode:
authorCraig Jennings <c@cjennings.net>2026-05-11 10:02:17 -0500
committerCraig Jennings <c@cjennings.net>2026-05-11 10:02:17 -0500
commit949bdeb3ac4d7b027cdd88efd54cc8c121f8c5d3 (patch)
tree64e1302958d949533e43e8a17e86b5c55d8e2ab0 /tests/test-vterm-copy-mode-cursor.el
parent071fb5e972a08e4072d9177d493928ceb26763f4 (diff)
downloaddotemacs-949bdeb3ac4d7b027cdd88efd54cc8c121f8c5d3.tar.gz
dotemacs-949bdeb3ac4d7b027cdd88efd54cc8c121f8c5d3.zip
feat(vterm): unify the keys in vterm copy-mode and tmux history
`vterm-copy-mode' and the `C-; x h' tmux-history buffer now share one key story. `M-w' copies the active region and stays put, so I can copy several things in a row. `C-g', `<escape>', or `q' leaves (resuming the live terminal, or closing the history buffer) without copying. `RET' is unbound (no special "copy and exit"). In copy-mode that meant removing vterm's default `RET' -> `vterm-copy-mode-done' binding. Before, `M-w' exited and copied as it went, which made grabbing more than one selection awkward. The history buffer's `cj/vterm-tmux-history-copy-and-quit' was the copy-and-exit one-shot. It's gone. `M-w' then `q' is the equivalent. I also moved `cj/vterm-tmux-history' from `C-; x C' to `C-; x h' (unshifted, and it frees `C') and refreshed the file's stale commentary header, which still referenced the old `C-; V' prefix and `<pause>'.
Diffstat (limited to 'tests/test-vterm-copy-mode-cursor.el')
-rw-r--r--tests/test-vterm-copy-mode-cursor.el7
1 files changed, 4 insertions, 3 deletions
diff --git a/tests/test-vterm-copy-mode-cursor.el b/tests/test-vterm-copy-mode-cursor.el
index 49625405..c549a44f 100644
--- a/tests/test-vterm-copy-mode-cursor.el
+++ b/tests/test-vterm-copy-mode-cursor.el
@@ -81,9 +81,10 @@ restore function -- not just the helper in isolation."
(should-not (local-variable-p 'cursor-type))))
(ert-deftest test-vterm-copy-mode-cursor-end-to-end-via-copy-done ()
- "Normal: `vterm-copy-mode-done' (M-w / RET binding) toggles copy-mode
-off and triggers cursor restoration. This is the path the user takes
-most often -- copy and exit in one keystroke."
+ "Normal: `vterm-copy-mode-done' toggles copy-mode off and triggers cursor
+restoration. No key is bound to it in this config (M-w copies and stays;
+RET is unbound), but it stays reachable via \\[execute-extended-command]
+and its exit path must still restore the cursor."
(test-vterm-copy-mode-cursor--in-fake-vterm-buffer
(setq-local cursor-type nil)
(vterm-copy-mode 1)