This commit is contained in:
Mars 2024-10-12 19:41:12 -04:00
parent d999844f20
commit a20cfa6659
Signed by: pupbrained
GPG key ID: 874E22DF2F9DFCB5

View file

@ -188,6 +188,13 @@
(setq-default whitespace-action (setq-default whitespace-action
'(cleanup auto-cleanup)) '(cleanup auto-cleanup))
(defun my/vterm-toggle-project-root ()
"Open or toggle vterm at the project root."
(interactive)
(let ((default-directory (or (project-root (project-current))
default-directory)))
(vterm-toggle)))
(use-package general (use-package general
:ensure t :ensure t
:config :config
@ -195,7 +202,7 @@
:states '(normal visual emacs) :states '(normal visual emacs)
:keymaps 'override :keymaps 'override
"K" '(eldoc-box-help-at-point :wk "Hover") "K" '(eldoc-box-help-at-point :wk "Hover")
"C-t" '(vterm-toggle :wk "Toggle VTerm"))) "C-t" '(my/vterm-toggle-project-root :wk "Toggle VTerm")))
(use-package evil-collection (use-package evil-collection
:ensure t :ensure t