aboutsummaryrefslogtreecommitdiff
path: root/modules/ai-config.el
diff options
context:
space:
mode:
authorCraig Jennings <c@cjennings.net>2026-05-07 19:25:18 -0500
committerCraig Jennings <c@cjennings.net>2026-05-07 19:25:18 -0500
commit47b218ed15acd00c18cbc3bef604c4f2e0050a08 (patch)
tree98c6541327b707e1e3c1f214f8a6dc7d0135a039 /modules/ai-config.el
parent3efaf9b5218fa769a297df5821ec89837207e57d (diff)
downloaddotemacs-47b218ed15acd00c18cbc3bef604c4f2e0050a08.tar.gz
dotemacs-47b218ed15acd00c18cbc3bef604c4f2e0050a08.zip
feat(ai-vterm): add Claude launcher with vertical-split vterm
The new module picks a Claude-template project from a filtered completing-read list. It scans the same roots the `ai` shell launcher uses, then opens or reuses a vterm buffer named `claude [<repo>]` on the right. F9 launches it. The prior `cj/toggle-gptel` binding moves from F9 to C-F9 so both AI tools share the same physical key. The display rule chains reuse-window -> use-some-window -> in-direction (right). The resulting window isn't dedicated. That matters because side-window dedication was breaking `buffer-move` (C-M-arrows) and `switch-to-buffer` replacement on the claude buffer. I also narrowed `vterm-toggle`'s display rule to skip `claude [` buffers. Otherwise it claimed them first with its bottom-split + dedicated treatment. I added 23 tests across 5 files: the buffer-name transform, candidate walker, show-or-create dispatch, picker, and display rule. Design lives at docs/design/ai-vterm.org.
Diffstat (limited to 'modules/ai-config.el')
-rw-r--r--modules/ai-config.el4
1 files changed, 3 insertions, 1 deletions
diff --git a/modules/ai-config.el b/modules/ai-config.el
index d3765ab8..779862bc 100644
--- a/modules/ai-config.el
+++ b/modules/ai-config.el
@@ -28,6 +28,8 @@
;;; Code:
+(require 'keybindings) ;; provides cj/custom-keymap
+
(autoload 'cj/gptel-save-conversation "ai-conversations" "Save the AI conversation to a file." t)
(autoload 'cj/gptel-load-conversation "ai-conversations" "Load a saved AI conversation." t)
(autoload 'cj/gptel-delete-conversation "ai-conversations" "Delete a saved AI conversation." t)
@@ -310,7 +312,7 @@ Works for any buffer, whether it's visiting a file or not."
:defer t
:commands (gptel gptel-send gptel-menu)
:bind
- (("<f9>" . cj/toggle-gptel)
+ (("C-<f9>" . cj/toggle-gptel)
:map gptel-mode-map
("C-<return>" . gptel-send))
:custom