4 ms·
My apologies for missing this! Eglot is a package that works with LSP (Language Servers). There is another one called lsp-mode. Eglot is integrated within Ema
by cyrialize 3y ago
My apologies for missing this!
Eglot is a package that works with LSP (Language Servers). There is another one called lsp-mode.
Eglot is integrated within Emacs over lsp-mode because it was specifically made to use existing hooks that Emacs has.
What this means is that you'd use the base Emacs command for finding a reference, and Eglot will populate the source for that command.
Whereas with lsp-mode, it has it's own command you'd run for finding reference. I do think you could also write code to have lsp-mode populate Emacs commands.
That being said, my impression is that Eglot has better integration with Emacs - which is why it became part of Emacs core.
(It's been a while since I've reviewed the Eglot vs lsp-mode discussions, so anyone feel free to correct me).
Use-package is a package for setting up your Emacs configurations. It allows you to place settings for individual packages in nice little sections. It's mainly used for organization but you also gain a plethora of options as well, like deferring to load a package until you open a file that requires it.
You also don't technically need to configure Emacs by hand by writing code lines. You could always do M-x customize and change settings that way. Emacs will auto-generate code from that and place it at the end of your configuration file.
That being said, this becomes quite messy to look at - so people prefer to use M-x customize to find the setting they want, and then they write it by hand in their config.
A big usage of use-package that I love is that you could specify specific settings that tell Emacs to enable it through M-x customize. If you don't know what I mean by that - that is totally ok. You'll learn about this more if you ever dive into Emacs and want to configure your own settings.