mirror of
https://github.com/larstvei/dot-emacs.git
synced 2024-11-26 07:28:31 +00:00
Remove lsp, add eglot
This commit is contained in:
parent
adb572c427
commit
751bec6eb2
28
init.org
28
init.org
@ -203,9 +203,6 @@
|
|||||||
ivy-posframe ; Using posframe to show Ivy
|
ivy-posframe ; Using posframe to show Ivy
|
||||||
jedi ; Python auto-completion for Emacs
|
jedi ; Python auto-completion for Emacs
|
||||||
js2-mode ; Improved JavaScript editing mode
|
js2-mode ; Improved JavaScript editing mode
|
||||||
lsp-java ; Java support for lsp-mode
|
|
||||||
lsp-mode ; LSP mode
|
|
||||||
lsp-ui ; UI modules for lsp-mode
|
|
||||||
magit ; control Git from Emacs
|
magit ; control Git from Emacs
|
||||||
markdown-mode ; Emacs Major mode for Markdown-formatted files
|
markdown-mode ; Emacs Major mode for Markdown-formatted files
|
||||||
maude-mode ; Emacs mode for the programming language Maude
|
maude-mode ; Emacs mode for the programming language Maude
|
||||||
@ -868,19 +865,6 @@
|
|||||||
#+END_SRC
|
#+END_SRC
|
||||||
|
|
||||||
* Mode specific
|
* Mode specific
|
||||||
** LSP
|
|
||||||
|
|
||||||
LSP mode works really well, especially with languages like Java, which
|
|
||||||
traditionally has had quite poor Emacs support.
|
|
||||||
|
|
||||||
#+BEGIN_SRC emacs-lisp
|
|
||||||
(with-eval-after-load 'lsp-mode
|
|
||||||
(define-key lsp-mode-map (kbd "C-c f") lsp-command-map)
|
|
||||||
(add-hook 'lsp-mode-hook #'lsp-enable-which-key-integration)
|
|
||||||
(add-hook 'lsp-mode-hook #'yas-minor-mode)
|
|
||||||
(add-hook 'lsp-mode-hook (lambda () (lsp-headerline-breadcrumb-mode 0)))
|
|
||||||
(add-to-list 'lsp-file-watch-ignored-directories "[/\\\\]\\.hypothesis\\'"))
|
|
||||||
#+END_SRC
|
|
||||||
|
|
||||||
** Compilation
|
** Compilation
|
||||||
|
|
||||||
@ -1040,7 +1024,7 @@
|
|||||||
activated.
|
activated.
|
||||||
|
|
||||||
#+BEGIN_SRC emacs-lisp
|
#+BEGIN_SRC emacs-lisp
|
||||||
(add-hook 'java-mode-hook 'lsp)
|
(add-hook 'java-mode-hook 'eglot-ensure)
|
||||||
#+END_SRC
|
#+END_SRC
|
||||||
|
|
||||||
** Assembler
|
** Assembler
|
||||||
@ -1219,8 +1203,14 @@
|
|||||||
** Rust
|
** Rust
|
||||||
|
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp
|
||||||
(setq lsp-rust-server 'rust-analyzer)
|
(add-hook 'rust-mode-hook 'eglot-ensure)
|
||||||
(setq lsp-rust-analyzer-cargo-watch-command "clippy")
|
#+end_src
|
||||||
|
|
||||||
|
** Go
|
||||||
|
|
||||||
|
#+begin_src emacs-lisp
|
||||||
|
(add-to-list 'auto-mode-alist '("\\.go\\'" . go-mode))
|
||||||
|
(add-hook 'go-mode-hook 'eglot-ensure)
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
* Key bindings
|
* Key bindings
|
||||||
|
Loading…
Reference in New Issue
Block a user