<feed xmlns='http://www.w3.org/2005/Atom'>
<title>dotemacs/tests/test-vterm-tmux-history.el, branch load-graph-classify-end</title>
<subtitle>My Emacs configuration
</subtitle>
<id>https://git.cjennings.net/dotemacs/atom?h=load-graph-classify-end</id>
<link rel='self' href='https://git.cjennings.net/dotemacs/atom?h=load-graph-classify-end'/>
<link rel='alternate' type='text/html' href='https://git.cjennings.net/dotemacs/'/>
<updated>2026-05-18T21:00:08+00:00</updated>
<entry>
<title>feat(vterm): forward &lt;escape&gt; to the pty in vterm-mode</title>
<updated>2026-05-18T21:00:08+00:00</updated>
<author>
<name>Craig Jennings</name>
<email>c@cjennings.net</email>
</author>
<published>2026-05-18T21:00:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cjennings.net/dotemacs/commit/?id=55fb9102c70dc272d4267aec30eed4860f3abdf5'/>
<id>urn:sha1:55fb9102c70dc272d4267aec30eed4860f3abdf5</id>
<content type='text'>
`&lt;escape&gt;' is bound globally to `keyboard-escape-quit' in
modules/keybindings.el, so Emacs swallows the key before it can reach the
pty. Bind it in vterm-mode-map to cj/vterm-send-escape, which writes a
literal ESC byte via vterm-send-string. tmux's copy-mode `cancel' binding
then fires; vi-mode exits, fzf cancel, etc., also work as expected.
</content>
</entry>
<entry>
<title>feat(vterm): forward wheel events and route C-; x c into tmux copy-mode</title>
<updated>2026-05-18T20:49:29+00:00</updated>
<author>
<name>Craig Jennings</name>
<email>c@cjennings.net</email>
</author>
<published>2026-05-18T20:49:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cjennings.net/dotemacs/commit/?id=0202a65825441562eb9903ccc28939367e29c274'/>
<id>urn:sha1:0202a65825441562eb9903ccc28939367e29c274</id>
<content type='text'>
vterm-mode-map binds only mouse-1 and mouse-yank-primary, so wheel events
fall through to Emacs scrolling and never reach the pty. tmux's `set -g
mouse on' never sees them. Bind wheel-up / wheel-down (and X11 mouse-4 /
mouse-5) to send SGR mouse-wheel escapes via vterm-send-string. tmux's
existing WheelUpPane / WheelDownPane bindings route into copy-mode from
there.

For keyboard parity, route C-; x c through cj/vterm-copy-mode-dwim, which
sends C-b [ when a tmux client is attached and falls back to vterm-copy-mode
otherwise. tmux's history-limit is now reachable from either entry point.
The matching copy-mode keys (M-w stays, C-g / q / Escape exit, Enter
unbound) land in the dotfiles repo alongside.
</content>
</entry>
<entry>
<title>feat(vterm): show tmux scrollback history in place</title>
<updated>2026-05-13T20:39:40+00:00</updated>
<author>
<name>Craig Jennings</name>
<email>c@cjennings.net</email>
</author>
<published>2026-05-13T20:39:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cjennings.net/dotemacs/commit/?id=c3ec8508a8ff414d099d9e567eb5ffd43a9c93f2'/>
<id>urn:sha1:c3ec8508a8ff414d099d9e567eb5ffd43a9c93f2</id>
<content type='text'>
`cj/vterm-tmux-history' previously used `pop-to-buffer', which routed the history view through display-buffer-alist -- in an agent window that often meant a split or a hand-off to another window, costing the agent its frame slot. `switch-to-buffer' instead drops the history into the selected window directly; the existing quit handler already restores the origin in that same window via `set-window-buffer'.

New test asserts the in-place behavior: starting single-window with a vterm origin, invoking the command leaves `(one-window-p)` t with the history buffer in the original slot. The existing render test no longer needs its `pop-to-buffer' stub since `switch-to-buffer' works in batch.
</content>
</entry>
<entry>
<title>feat(vterm): unify the keys in vterm copy-mode and tmux history</title>
<updated>2026-05-11T15:02:17+00:00</updated>
<author>
<name>Craig Jennings</name>
<email>c@cjennings.net</email>
</author>
<published>2026-05-11T15:02:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cjennings.net/dotemacs/commit/?id=949bdeb3ac4d7b027cdd88efd54cc8c121f8c5d3'/>
<id>urn:sha1:949bdeb3ac4d7b027cdd88efd54cc8c121f8c5d3</id>
<content type='text'>
`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', `&lt;escape&gt;', 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' -&gt; `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 `&lt;pause&gt;'.
</content>
</entry>
<entry>
<title>refactor(ai-vterm): rename Claude-specific names to a generic "agent"</title>
<updated>2026-05-11T12:18:20+00:00</updated>
<author>
<name>Craig Jennings</name>
<email>c@cjennings.net</email>
</author>
<published>2026-05-11T12:18:20+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cjennings.net/dotemacs/commit/?id=59b0854464ef29511a0d09f1e76fd1140e675833'/>
<id>urn:sha1:59b0854464ef29511a0d09f1e76fd1140e675833</id>
<content type='text'>
I may add other terminal agents to this launcher (aider, an open-source LLM TUI), so the buffer prefix, the user knob, and the internal helpers shouldn't say "Claude". The module name (ai-vterm) and the `cj/ai-vterm-*` customs were already generic. This finishes the job:

- buffer prefix `claude [&lt;basename&gt;]` -&gt; `agent [&lt;basename&gt;]` (the `defconst` and the matching display-buffer-alist regex move together)
- `cj/ai-vterm-claude-command` -&gt; `cj/ai-vterm-agent-command` (the default still runs the `claude` CLI, with a docstring note on swapping it)
- `cj/--ai-vterm-claude-buffers` / `-displayed-claude-window` / `-reuse-existing-claude` -&gt; `-agent-*`, and their test files renamed to match
- prose in the module commentary and docstrings, plus the matching test docstrings and buffer-name literals

`vterm-config.el` hardcodes the same buffer prefix in `cj/--vterm-toggle-buffer-p` (F12 excludes agent buffers from its candidate set), so that literal moved too. Collapsing it into the shared `cj/--ai-vterm-name-prefix` is a cleanup for another day.

After a reload, a project's buffer opens as `agent [foo]` instead of `claude [foo]`. Old buffers keep their names until killed. I also corrected two stale `eshell-vterm-config.el` references in ai-vterm.el docstrings (that module was split into `vterm-config.el`).

Two things keep saying "Claude": the `cj/ai-vterm-agent-command` default value (the actual CLI), and the "Claude Code" example in `vterm-config.el`'s cursor-restore docstring (a concrete TUI example, not branding).

90 tests pass. `make validate-modules` clean.
</content>
</entry>
<entry>
<title>test(vterm): cover AI-vterm inheritance of the vterm copy path</title>
<updated>2026-05-11T10:17:44+00:00</updated>
<author>
<name>Craig Jennings</name>
<email>c@cjennings.net</email>
</author>
<published>2026-05-11T10:17:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cjennings.net/dotemacs/commit/?id=364d69dc6f9be5d310c0ac1f0c69c31b08d82821'/>
<id>urn:sha1:364d69dc6f9be5d310c0ac1f0c69c31b08d82821</id>
<content type='text'>
I added three ERT cases around `cj/vterm--current-tmux-pane-id` and `cj/vterm-copy-mode-cancel`: the pane-id lookup rejects a non-`vterm-mode` buffer, it still resolves a `claude [...]`-named buffer by process TTY, and the copy-mode cancel command errors outside copy mode. The pane-id-by-TTY case pins the contract that AI-vterm buffers get the copy commands because they're `vterm-mode` buffers, not because of any buffer-name check.
</content>
</entry>
<entry>
<title>refactor(vterm): move vterm prefix to C-; x and add prompt nav</title>
<updated>2026-05-10T17:39:44+00:00</updated>
<author>
<name>Craig Jennings</name>
<email>c@cjennings.net</email>
</author>
<published>2026-05-10T17:39:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cjennings.net/dotemacs/commit/?id=5eccbf7bd3c9780eee6170839dbf3224a32e9ef3'/>
<id>urn:sha1:5eccbf7bd3c9780eee6170839dbf3224a32e9ef3</id>
<content type='text'>
The personal vterm map was on `C-; V'. The capital V costs a Shift on every keystroke into the menu, which adds up for the daily `C-; V c' / `C-; V C' bindings. Move the prefix to lowercase `C-; x' -- free, no Shift, faintly mnemonic (xterm/execute). The lowercase `C-; v' stays the version-control menu.

Wire `vterm-next-prompt' and `vterm-previous-prompt' into the menu so they're reachable everywhere, not only inside vterm-copy-mode-map. Lowercase `n' and `p' match Emacs's idiom for next/previous; bump "new vterm" up to capital `N' for the rare new-buffer case.

Drop the `&lt;pause&gt;' binding for `vterm-copy-mode' from `vterm-mode-map'. Modern keyboards rarely have a Pause key and `C-; x c' is the canonical entry now.

Update which-key labels and tests; `test-vterm-keymap-includes-history-and-copy-bindings' now asserts the new prefix, and two new tests cover prompt-nav bindings and the dropped `&lt;pause&gt;' binding.
</content>
</entry>
<entry>
<title>refactor: split eshell-vterm-config into eshell-config and vterm-config</title>
<updated>2026-05-10T08:25:35+00:00</updated>
<author>
<name>Craig Jennings</name>
<email>c@cjennings.net</email>
</author>
<published>2026-05-10T08:25:35+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cjennings.net/dotemacs/commit/?id=b099c779343119ce40f2636469e118ec104002e0'/>
<id>urn:sha1:b099c779343119ce40f2636469e118ec104002e0</id>
<content type='text'>
The combined module had grown to 573 lines covering two unrelated subsystems with no shared state — the eshell shell-mode commands and the vterm/F12 toggle. The header even rendered this with two `;; ----` dividers. Split into two focused modules. eshell-config.el keeps the eshell user commands and package wiring (~170 lines). vterm-config.el keeps the vterm package, the tmux history capture command, the F12 toggle, and the C-; V keymap (~400 lines). Update init.el to require both, point the four vterm test files at vterm-config, and refresh the cross-module commentary in cj-window-geometry.el and cj-window-toggle.el.

No behavior change. Full test suite green; validate-modules clean.
</content>
</entry>
<entry>
<title>Add Emacs-native vterm copy workflows</title>
<updated>2026-05-10T07:44:21+00:00</updated>
<author>
<name>Craig Jennings</name>
<email>c@cjennings.net</email>
</author>
<published>2026-05-10T07:44:21+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cjennings.net/dotemacs/commit/?id=fe937e752243107bead6e7711dea5a231a853d92'/>
<id>urn:sha1:fe937e752243107bead6e7711dea5a231a853d92</id>
<content type='text'>
Add an Emacs-first copy workflow for vterm and tmux. C-; V c enters vterm copy mode, C-; V C captures tmux pane scrollback into a temporary Emacs buffer, M-w copies and returns, and C-g/Escape cancel without copying. This also adds clickable URLs, removes the bad vtermf binding, unbinds C-c C-t, and tests the vterm/tmux keymap behavior.
</content>
</entry>
</feed>
