Skip to content

Commit

Permalink
Don't enable lsp-ui-mode in lsp--auto-configure
Browse files Browse the repository at this point in the history
Using a hook instead is more sensible (users can trivially configure
it).
  • Loading branch information
hlissner committed May 18, 2021
1 parent d141f39 commit 69bd3da
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions modules/tools/lsp/+lsp.el
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,14 @@ server getting expensively restarted when reverting buffers."

(use-package! lsp-ui
:hook (lsp-mode . lsp-ui-mode)
:init
(defadvice! +lsp--use-hook-instead-a (orig-fn &rest args)
"Change `lsp--auto-configure' to not force `lsp-ui-mode' on us. Using a hook
instead is more sensible."
:around #'lsp--auto-configure
(letf! ((#'lsp-ui-mode #'ignore))
(apply orig-fn args)))

:config
(when (featurep! +peek)
(set-lookup-handlers! 'lsp-ui-mode
Expand Down

0 comments on commit 69bd3da

Please sign in to comment.