diff --git a/doom/.config/doom/README.org b/doom/.config/doom/README.org index 7268777..052d6ce 100644 --- a/doom/.config/doom/README.org +++ b/doom/.config/doom/README.org @@ -2000,12 +2000,13 @@ already saved to ~.hermes-sessions~ at the project root. ;; ------------------------------------------------------------------- ;; Org link type: [[hermes:20260718_162500_a1b2c3][Resume — Title]] ;; ------------------------------------------------------------------- -(org-link-set-parameters "hermes" - :follow (lambda (id) - (gortium/hermes--open-vterm - (format "hermes chat --resume %s" id) - "*hermes*")) - :help-echo "Resume this Hermes chat session in vterm") +(after! org + (org-link-set-parameters "hermes" + :follow (lambda (id) + (gortium/hermes--open-vterm + (format "hermes chat --resume %s" id) + (format "*hermes-%s*" id))) + :help-echo "Resume this Hermes chat session in vterm")) ;; ------------------------------------------------------------------- ;; Helpers — build commands, detect project @@ -2105,7 +2106,6 @@ Remote needs ssh -t + docker exec -it (PTY required)." ;; ------------------------------------------------------------------- ;; Start a new Hermes session (with title prompt) ;; ------------------------------------------------------------------- -;;;###autoload (defun gortium/hermes-start (title &optional remote-host) "Start a new Hermes session for the current project. With prefix arg, prompt for remote SSH host (default: lazyworkhorse)." @@ -2122,12 +2122,11 @@ With prefix arg, prompt for remote SSH host (default: lazyworkhorse)." (gortium/hermes-append-session sfile id title) (gortium/hermes--open-vterm (gortium/hermes--launch-cmd id remote-host) - (format "*hermes-%s*" name))))) + (format "*hermes-%s*" id))))) ;; ------------------------------------------------------------------- ;; Browse / resume past sessions (completing-read menu) ;; ------------------------------------------------------------------- -;;;###autoload (defun gortium/hermes-resume () "Browse and resume a past Hermes session from the current project." (interactive) @@ -2161,12 +2160,12 @@ With prefix arg, prompt for remote SSH host (default: lazyworkhorse)." (session (nth idx sessions)) (id (plist-get session :id))) (gortium/hermes--open-vterm - (format "hermes chat --resume %s" id)))))))) + (format "hermes chat --resume %s" id) + (format "*hermes-%s*" id)))))))) ;; ------------------------------------------------------------------- ;; Link external session to current project ;; ------------------------------------------------------------------- -;;;###autoload (defun gortium/hermes-link-session (session-id title) "Link an existing Hermes session to the current project. If SESSION-ID is empty, show a menu of recent sessions to browse." @@ -2213,7 +2212,6 @@ If SESSION-ID is empty, show a menu of recent sessions to browse." ;; ------------------------------------------------------------------- ;; Remove a linked session from project ;; ------------------------------------------------------------------- -;;;###autoload (defun gortium/hermes-remove-session () "Remove a Hermes session from the current project's .hermes-sessions." (interactive) diff --git a/doom/.config/doom/config.el b/doom/.config/doom/config.el index e6e9e8a..a6536d4 100644 --- a/doom/.config/doom/config.el +++ b/doom/.config/doom/config.el @@ -1196,12 +1196,13 @@ DIFF: ;; ------------------------------------------------------------------- ;; Org link type: [[hermes:20260718_162500_a1b2c3][Resume — Title]] ;; ------------------------------------------------------------------- -(org-link-set-parameters "hermes" - :follow (lambda (id) - (gortium/hermes--open-vterm - (format "hermes chat --resume %s" id) - "*hermes*")) - :help-echo "Resume this Hermes chat session in vterm") +(after! org + (org-link-set-parameters "hermes" + :follow (lambda (id) + (gortium/hermes--open-vterm + (format "hermes chat --resume %s" id) + (format "*hermes-%s*" id))) + :help-echo "Resume this Hermes chat session in vterm")) ;; ------------------------------------------------------------------- ;; Helpers — build commands, detect project @@ -1301,7 +1302,6 @@ Remote needs ssh -t + docker exec -it (PTY required)." ;; ------------------------------------------------------------------- ;; Start a new Hermes session (with title prompt) ;; ------------------------------------------------------------------- -;;;###autoload (defun gortium/hermes-start (title &optional remote-host) "Start a new Hermes session for the current project. With prefix arg, prompt for remote SSH host (default: lazyworkhorse)." @@ -1318,12 +1318,11 @@ With prefix arg, prompt for remote SSH host (default: lazyworkhorse)." (gortium/hermes-append-session sfile id title) (gortium/hermes--open-vterm (gortium/hermes--launch-cmd id remote-host) - (format "*hermes-%s*" name))))) + (format "*hermes-%s*" id))))) ;; ------------------------------------------------------------------- ;; Browse / resume past sessions (completing-read menu) ;; ------------------------------------------------------------------- -;;;###autoload (defun gortium/hermes-resume () "Browse and resume a past Hermes session from the current project." (interactive) @@ -1357,12 +1356,12 @@ With prefix arg, prompt for remote SSH host (default: lazyworkhorse)." (session (nth idx sessions)) (id (plist-get session :id))) (gortium/hermes--open-vterm - (format "hermes chat --resume %s" id)))))))) + (format "hermes chat --resume %s" id) + (format "*hermes-%s*" id)))))))) ;; ------------------------------------------------------------------- ;; Link external session to current project ;; ------------------------------------------------------------------- -;;;###autoload (defun gortium/hermes-link-session (session-id title) "Link an existing Hermes session to the current project. If SESSION-ID is empty, show a menu of recent sessions to browse." @@ -1409,7 +1408,6 @@ If SESSION-ID is empty, show a menu of recent sessions to browse." ;; ------------------------------------------------------------------- ;; Remove a linked session from project ;; ------------------------------------------------------------------- -;;;###autoload (defun gortium/hermes-remove-session () "Remove a Hermes session from the current project's .hermes-sessions." (interactive)