diff options
| author | Craig Jennings <c@cjennings.net> | 2026-07-20 08:36:14 -0500 |
|---|---|---|
| committer | Craig Jennings <c@cjennings.net> | 2026-07-20 08:36:14 -0500 |
| commit | d9a8a6382854bb06c3aac6a5a4779a48cc82b48a (patch) | |
| tree | 833b5629f884b8acc52e76deb43775280ab8f0c1 /modules/ai-term-backend-eat.el | |
| parent | 836b386e0a19fe49d35a65ea4d0faa63e6d6e1d2 (diff) | |
| download | dotemacs-d9a8a6382854bb06c3aac6a5a4779a48cc82b48a.tar.gz dotemacs-d9a8a6382854bb06c3aac6a5a4779a48cc82b48a.zip | |
feat(ai-term): M-SPC cycles attached agents, M-S-SPC cycles all
M-SPC now steps only through attached agents (the ones with a live
on-screen buffer), so the fast chord stays among what's already up.
M-S-SPC steps through all active agents and attaches a detached tmux
session when it lands on one, which is what M-SPC used to do.
I moved the shared step logic into cj/--ai-term-step-among and added
cj/--ai-term-attached-agent-dirs to filter the queue to attached
buffers. I bound both chords globally and in eat-semi-char-mode-map so
they work from inside an agent buffer. C-; a n keeps cycling all.
Diffstat (limited to 'modules/ai-term-backend-eat.el')
| -rw-r--r-- | modules/ai-term-backend-eat.el | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/modules/ai-term-backend-eat.el b/modules/ai-term-backend-eat.el index be84ef25..a7781128 100644 --- a/modules/ai-term-backend-eat.el +++ b/modules/ai-term-backend-eat.el @@ -159,12 +159,14 @@ buffer." buf)))))) ;; In EAT's semi-char mode, keys not bound in `eat-semi-char-mode-map' are -;; forwarded to the pty. M-SPC (swap to the next agent) must reach Emacs from -;; inside an agent buffer, so bind it in that map -- no exception-list or rebuild +;; forwarded to the pty. The swap-to-next chords must reach Emacs from inside +;; an agent buffer, so bind them in that map -- no exception-list or rebuild ;; dance like ghostel needed. C-; is already bound there (eat-config), so the ;; C-; a family resolves through the global prefix without extra wiring. +;; M-SPC cycles attached agents only; M-S-SPC cycles all (attaching a detached). (with-eval-after-load 'eat - (keymap-set eat-semi-char-mode-map "M-SPC" #'cj/ai-term-next)) + (keymap-set eat-semi-char-mode-map "M-SPC" #'cj/ai-term-next-attached) + (keymap-set eat-semi-char-mode-map "M-S-SPC" #'cj/ai-term-next)) (provide 'ai-term-backend-eat) ;;; ai-term-backend-eat.el ends here |
