Proposal: eglot-base-workspace-configuration #1285
Ninjananas
started this conversation in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Motivation / Problem
I would like to define a default system-wide
eglot-workspace-configuration
and override some of it using a.dir-locals.el
on a per-project basis.Unfortunately, setting
eglot-workspace-configuration
overwrites the whole plist instead of merging the new value with it.Example:
Let's say that I want to enable globally jedi completion in pylsp
'(:pylsp (:plugins (:jedi_completion (:enabled t))))
And only for a specific project I would like to enable the
fuzzy
option'(:pylsp (:plugins (:jedi_completion (:fuzzy t))))
The merged settings would be
'(:pylsp (:plugins (:jedi_completion (:enabled t :fuzzy t))))
Quick solution
I have the following in my init.el:
Instead of setting
eglot-workspace-configuration
in my.dir-locals.el
, I set my owncustom/eglot-workspace-configuration
Proposal
I think it would be nice to add a new
eglot-base-workspace-configuration
variable that will be merged by eglot with the existingeglot-workspace-configuration
. This does not break existing functionality and makes easier to do what I achieve in myinit.el
.I think the "merge" function I'm using works fine for that case, but maybe I'm missing edge cases?
I can try to come out with a pull request if you think that it's a good idea, but I'm not an experienced (e)lisp developer.
Thanks for your time and for the wonderful eglot project !
Beta Was this translation helpful? Give feedback.
All reactions