1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-01-09 21:20:45 -08:00
emacs/doc
dannyfreeman 74a009dd96 Eglot: Handle LSP progress with Emacs progress reporters (bug#59149)
Co-authored-by: João Távora <joaotavora@gmail.com>

* lisp/progmodes/eglot.el (eglot-report-progress): New custom variable.
(eglot-lsp-server): New slot for tracking active progress reporters.
(eglot-handle-notification (eql $/progress)): New method.

The LSP spec describes methods for reporting progress on long running
jobs to the client:

https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#progress
https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#workDoneProgress

This change reports those notifications in the minibuffer as they come
in.  It shows a percent indicator (if the server provides theme), or a
spinner.

This change could open the door for writing a "cancel long running
request" command, which are identified by these progress
notifications.  See
https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#window_workDoneProgress_cancel

* doc/misc/eglot.texi (Customizing Eglot): Describe new variable.
2022-12-09 13:03:57 +00:00
..
emacs ; Fix typos 2022-12-08 07:17:47 +01:00
lispintro ; * doc/lispintro/emacs-lisp-intro.texi (Complete kill-region): Fix typo 2022-11-23 10:26:46 +01:00
lispref ; Clarify description of display on the margins 2022-12-05 21:45:01 +02:00
man ; Fix groff warnings in man pages 2022-12-09 11:15:21 +01:00
misc Eglot: Handle LSP progress with Emacs progress reporters (bug#59149) 2022-12-09 13:03:57 +00:00