Add eglot settings and optimizations
This commit is contained in:
@@ -852,6 +852,7 @@ Please [send me](https://www.jamescherti.com/contact/) your feedback and I'll ad
|
|||||||
10. **Miscellaneous**
|
10. **Miscellaneous**
|
||||||
- Configure recentf, savehist, and auto-save
|
- Configure recentf, savehist, and auto-save
|
||||||
- Configure Ediff to use a single frame and split windows horizontally
|
- Configure Ediff to use a single frame and split windows horizontally
|
||||||
|
- Optimize Eglot
|
||||||
|
|
||||||
## Author and license
|
## Author and license
|
||||||
|
|
||||||
|
|||||||
21
init.el
21
init.el
@@ -23,6 +23,7 @@
|
|||||||
(setq ffap-machine-p-known 'reject)
|
(setq ffap-machine-p-known 'reject)
|
||||||
|
|
||||||
;;; package.el
|
;;; package.el
|
||||||
|
|
||||||
(when (bound-and-true-p minimal-emacs-package-initialize-and-refresh)
|
(when (bound-and-true-p minimal-emacs-package-initialize-and-refresh)
|
||||||
;; Initialize and refresh package contents again if needed
|
;; Initialize and refresh package contents again if needed
|
||||||
(package-initialize)
|
(package-initialize)
|
||||||
@@ -431,7 +432,25 @@
|
|||||||
;; increasing their usefulness.
|
;; increasing their usefulness.
|
||||||
(setq apropos-do-all t)
|
(setq apropos-do-all t)
|
||||||
|
|
||||||
;;; Load post-init.el
|
;;; Eglot
|
||||||
|
|
||||||
|
(setq eglot-sync-connect 1
|
||||||
|
eglot-autoshutdown t)
|
||||||
|
|
||||||
|
;; Activate Eglot in cross-referenced non-project files
|
||||||
|
(setq eglot-extend-to-xref t)
|
||||||
|
|
||||||
|
;; Eglot optimization
|
||||||
|
(setq jsonrpc-event-hook nil)
|
||||||
|
(setq eglot-events-buffer-size 0)
|
||||||
|
(setq eglot-report-progress nil) ; Prevent Eglot minibuffer spam
|
||||||
|
|
||||||
|
;; Eglot optimization: Disable `eglot-events-buffer' to maintain consistent
|
||||||
|
;; performance in long-running Emacs sessions. By default, it retains 2,000,000
|
||||||
|
;; lines, and each new event triggers pretty-printing of the entire buffer,
|
||||||
|
;; leading to a gradual performance decline.
|
||||||
|
(setq eglot-events-buffer-config '(:size 0 :format full))
|
||||||
|
|
||||||
(minimal-emacs-load-user-init "post-init.el")
|
(minimal-emacs-load-user-init "post-init.el")
|
||||||
|
|
||||||
(provide 'init)
|
(provide 'init)
|
||||||
|
|||||||
Reference in New Issue
Block a user