corfu, term at project root

This commit is contained in:
Levi 2024-10-07 10:50:53 +02:00
parent dc11bac7f6
commit e190748bf6
2 changed files with 12 additions and 2 deletions

View File

@ -9,8 +9,8 @@
(require 'module-pkg)
(pkg/require 'corfu)
(setq corfu-cycle t) ;; Enable cycling for `corfu-next/previous'
(setq corfu-auto t) ;; Enable auto completion
(setq corfu-cycle nil) ;; Enable cycling for `corfu-next/previous'
(setq corfu-auto nil) ;; Enable auto completion
(setq corfu-separator ?\s) ;; Orderless field separator
(setq corfu-quit-at-boundary t) ;; Never quit at completion boundary
(setq corfu-quit-no-match t) ;; Never quit, even if there is no match

View File

@ -11,6 +11,16 @@
(projectile-mode +1)
(defun open-terminal-at-project-root ()
"Open an external terminal emulator at the project root directory."
(interactive)
(let* ((project-root (projectile-project-root))
(terminal-program "xterm")
(command (concat terminal-program " -e 'cd " project-root " && $SHELL'")))
(if project-root
(start-process-shell-command "external-terminal" nil command)
(message "Not in a project"))))
(provide 'module-projectile)
;;; module-projectile.el ends here.