aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoão Távora2023-12-18 17:59:29 -0600
committerJoão Távora2023-12-18 18:20:17 -0600
commit20e39a12e491ce82ee581b6d99a4e2770218e0c6 (patch)
tree752033ac65f080a029903dad3b708fe1d9f4d346
parent6937182a0e7735e83377c757ae13292692b0cb85 (diff)
downloademacs-20e39a12e491ce82ee581b6d99a4e2770218e0c6.tar.gz
emacs-20e39a12e491ce82ee581b6d99a4e2770218e0c6.zip
; Small copyedits to doc/misc/eglot.texi
Motivated in part by bug#67870 and bug#67609. * doc/misc/eglot.texi (Quick Start): Reword (Eglot Features): Reword. (Eglot Commands): Fix typo.
-rw-r--r--doc/misc/eglot.texi46
1 files changed, 28 insertions, 18 deletions
diff --git a/doc/misc/eglot.texi b/doc/misc/eglot.texi
index 5243a6530dc..eda93d84aff 100644
--- a/doc/misc/eglot.texi
+++ b/doc/misc/eglot.texi
@@ -138,11 +138,10 @@ Turn on Eglot for your project.
138To start using Eglot for a project, type @kbd{M-x eglot @key{RET}} in 138To start using Eglot for a project, type @kbd{M-x eglot @key{RET}} in
139a buffer visiting any file that belongs to the project. This starts 139a buffer visiting any file that belongs to the project. This starts
140the language server configured for the programming language of that 140the language server configured for the programming language of that
141buffer, and causes Eglot to start managing all the files of the 141buffer, and causes Eglot to start @dfn{managing} file-visiting buffers
142project which use the same programming language. This includes files 142related to that programming language. This includes files that are
143of a given project that are already visited at the time the 143already visited at the time the @code{eglot} command is invoked, as
144@code{eglot} command is invoked as well as files visited after this 144well as any files visited after this invocation.
145invocation.
146 145
147The notion of a ``project'' used by Eglot is the same Emacs uses 146The notion of a ``project'' used by Eglot is the same Emacs uses
148(@pxref{Projects,,, emacs, GNU Emacs Manual}): in the simplest case, 147(@pxref{Projects,,, emacs, GNU Emacs Manual}): in the simplest case,
@@ -405,11 +404,13 @@ commands and variables.
405@section Eglot Features 404@section Eglot Features
406@cindex features in buffers supported by Eglot 405@cindex features in buffers supported by Eglot
407 406
408Once Eglot is enabled in a buffer, it uses LSP and the language-server 407While Eglot is enabled in a buffer, it is said to be @dfn{managing}
409capabilities to activate, enable, and enhance modern IDE features in 408it, using LSP and the specific capabilities of the language server to
410Emacs. The features themselves are usually provided via other Emacs 409activate and enhance modern IDE features in Emacs. Some of these
411packages. Here's the list of the main features that Eglot enables and 410features are provided via other Emacs packages, and some via Eglot
412provides: 411directly (@pxref{Eglot Commands}).
412
413Here's an overview of the main features that Eglot provides:
413 414
414@itemize @bullet 415@itemize @bullet
415@item 416@item
@@ -422,10 +423,11 @@ allows major modes to provide extensive help and documentation about
422the program identifiers. 423the program identifiers.
423 424
424@item 425@item
425On-the-fly diagnostic annotations with server-suggested fixes, via the 426On-the-fly diagnostic annotations, via the Flymake package
426Flymake package (@pxref{Top,,, flymake, GNU Flymake manual}). This 427(@pxref{Top,,, flymake, GNU Flymake manual}). Eglot's Flymake backend
427improves and enhances the Flymake diagnostics, replacing the other 428replaces other Flymake backends while it is managing a buffer, and
428Flymake backends. 429enhances diagnostics with interactive server-suggested fixes
430(so-called @dfn{code actions}, @pxref{Eglot Commands})
429 431
430@item 432@item
431Finding definitions and uses of identifiers, via Xref (@pxref{Xref,,, 433Finding definitions and uses of identifiers, via Xref (@pxref{Xref,,,
@@ -484,9 +486,17 @@ with @kbd{eglot-code-actions}. @xref{Eglot Commands}.
484 486
485Not all servers support the full set of LSP capabilities, but most of 487Not all servers support the full set of LSP capabilities, but most of
486them support enough to enable the basic set of features mentioned 488them support enough to enable the basic set of features mentioned
487above. Conversely, some servers offer capabilities for which no 489above.
488equivalent Emacs package exists yet, and so Eglot cannot (yet) expose 490
489these capabilities to Emacs users. 491Conversely, some servers offer capabilities for which no equivalent
492Emacs package exists yet, and so Eglot cannot (yet) expose these
493capabilities to Emacs users. However, @xref{Extending Eglot}.
494
495Finally, it's worth noting that, by default, Eglot generally turns on
496all features that it @emph{can} turn on. It's possible to opt out of
497some features via user options (@pxref{Customizing Eglot}) and a hook
498that runs after Eglot starts managing a buffer (@pxref{Eglot and
499Buffers}).
490 500
491@node Eglot and Buffers 501@node Eglot and Buffers
492@section Buffers, Projects, and Eglot 502@section Buffers, Projects, and Eglot
@@ -694,7 +704,7 @@ requests for the language server to provide editing commands for
694correcting, refactoring or beautifying your code. These commands may 704correcting, refactoring or beautifying your code. These commands may
695affect more than one visited file belonging to the project. 705affect more than one visited file belonging to the project.
696 706
697The command @code{eglot-code-actions} asks the server if there any 707The command @code{eglot-code-actions} asks the server if there are any
698code actions for any point in the buffer or contained in the active 708code actions for any point in the buffer or contained in the active
699region. If there are, you have the choice to execute one of them via 709region. If there are, you have the choice to execute one of them via
700the minibuffer. 710the minibuffer.