BREAKING CHANGE: break the global nature of the tree sitter
module by adding a +tree-sitter flag to every applicable module
In the background this hooks turn-on-tree-sitter-mode
to the major-mode-hook of the language.
This may also solve the eager loading of tree sitter
We unset ccls-sem-highlight-method buffer-locally, but
lsp-before-initialize-hook only runs once per new LSP server instance,
and each server could preside over any number of buffers, so only the
first buffer is affected.
1. Unset ccls-sem-highlight-method if lsp-enable-semantic-highlighting
is nil (perhaps this should be reported upstream).
2. Fix load-order. Take `(use-package X :after Y :config Z)` for
example. Z will be evaluated after Y loads, not after X loads. To
customize Z you'd need to do `(after! Y ...)`. This is
counter-intuitive. By removing `:after Y` and explicitly loading X
when Y loads in :init, you can customize Z with `(after! X ...)` again.
3. Tie ccls-code-lens-mode to lsp-lens-mode, so lsp-lens-enable is
respected.
I should find some way to test on Mac OS I guess, or test at least. That would make those small errors easier to catch than trying to review it 1000 times
Most of these changes come from MaskRay's private configuration found
here :
c078dfad34/home/.config/doom/modules/private/my-cc/config.el
- Limit ccls threads to be maximum half the available core count on
Linux and MacOS
- Add wrappers to call ccls LSP extensions
- Enable ccls-code-lens-mode
- Set initial state to emacs when navigating ccls-tree
- Use 'font-lock for semantic highlighting, making the speed choice
according to variable's docstring
- config tweaks to eglot
InitializationOptions aren't handled this way. An example of handling
ccls init options is provided on joaotavora/eglot#545, hoping that a fix
gets merged upstream instead of having to handle ccls specifics in Doom
only
- Update README
- Add eglot-specifics to cc, rs, py, hs
removing unused lsp-mode packages when eglot is active
- Add eglot-specific bindings
- Add doctor warnings for debugger +lsp and +peek
- Add eglot-backed lookup-handlers
- Add flycheck checker using eglot for :checkers
syntax users (using flycheck/flycheck#1676 and
flycheck/flycheck#1592 discussion).
This implementation is based on @marsam code, and uses recent
Flycheck development in order to make the code smaller and
easier to maintain.
This update may potentially break your usage of add-hook! if you pass
the :local or :append properties to it. This is how they used to work:
(add-hook! :append 'some-mode-hook #'do-something)
Thsoe properties must now follow the hooks, e.g.
(add-hook! 'some-mode-hook :append #'do-something)
Other changes:
- Various add-hook calls have been renamed to add-hook! because I
incorrectly assumed `defun` always returned its definition's symbol,
when in fact, its return value is "undefined" (so sayeth the
documentation). This should fix#1597.
- This update adds the ability to add multiple functions to hooks
without a list:
(add-hook! 'some-mode-hook
#'do-something
#'do-something-else)
- The indentation logic has been changed so that consecutive function
symbols at indented at the same level as the first argument, but forms
are indent like a defun.
(add-hook! 'some-mode-hook
#'do-something
#'do-something-else)
(add-hook! 'some-mode-hook
(message "Hello"))
Calling this pivotal macro "def-package!" has frequently been a source
of confusion. It is a thin wrapper around use-package, and it should be
obvious that it is so. For this reason, and to match the naming
convention used with other convenience macros/wrappers, it is now
use-package!.
Also changes def-package-hook! -> use-package-hook!
The old macros are now marked obsolete and will be removed when straight
integration is merged.
+ Fix ffap integration
+ Code reduction for irony, rtags and lsp init hooks
+ Use c-add-style instead of unless+push
+ Log that irony server isn't installed