Add hook to enable eglot in prog-mode
This commit is contained in:
parent
d9802d98ae
commit
454d446077
|
@ -384,6 +384,11 @@
|
||||||
(use-package direnv
|
(use-package direnv
|
||||||
:config (direnv-mode +1))
|
:config (direnv-mode +1))
|
||||||
|
|
||||||
|
(when (require 'eglot nil :noerror)
|
||||||
|
;; Currently just using prog-mode
|
||||||
|
;; Should probably use individual language modes
|
||||||
|
;; One day...
|
||||||
|
(add-hook 'prog-mode-hook #'eglot-ensure))
|
||||||
;;; Eglot
|
;;; Eglot
|
||||||
(defun crafted-ide--add-eglot-hooks (mode-list)
|
(defun crafted-ide--add-eglot-hooks (mode-list)
|
||||||
"Add `eglot-ensure' to modes in MODE-LIST.
|
"Add `eglot-ensure' to modes in MODE-LIST.
|
||||||
|
|
|
@ -448,6 +448,11 @@ For reference information, see [[https://orgmode.com][Org-mode website]]
|
||||||
|
|
||||||
** Eglot LSP
|
** Eglot LSP
|
||||||
#+BEGIN_SRC emacs-lisp
|
#+BEGIN_SRC emacs-lisp
|
||||||
|
(when (require 'eglot nil :noerror)
|
||||||
|
;; Currently just using prog-mode
|
||||||
|
;; Should probably use individual language modes
|
||||||
|
;; One day...
|
||||||
|
(add-hook 'prog-mode-hook #'eglot-ensure))
|
||||||
;;; Eglot
|
;;; Eglot
|
||||||
(defun crafted-ide--add-eglot-hooks (mode-list)
|
(defun crafted-ide--add-eglot-hooks (mode-list)
|
||||||
"Add `eglot-ensure' to modes in MODE-LIST.
|
"Add `eglot-ensure' to modes in MODE-LIST.
|
||||||
|
|
Loading…
Reference in a new issue