lsp-haskell icon indicating copy to clipboard operation
lsp-haskell copied to clipboard

Configuration boilerplate

Open alanz opened this issue 3 years ago • 3 comments

With https://github.com/haskell/haskell-language-server/pull/691 we are introducing a boilerplate style of configuration per plugin, where each gets a global on/off switch, as well as being able to individually turn off parts of a plugin.

At some (hopefully soon) point we will be able to install a custom set of plugins (as proposed here).

So I think we need a meta-config, which can be provided with a list of plugins that are installed in the HLS exe, and generates customization and config entries for each of them.

alanz avatar Dec 21 '20 16:12 alanz

It would be kind of nice to support the JSON configuration that other clients do. Maybe we could talk to the lsp-mode folks about that. However, from a discoverability point of view, it's very nice to have an explicit listing of all the options that you can see with customize!

michaelpj avatar Dec 21 '20 18:12 michaelpj

I was wondering if we could do some sort of package deal configuration thing for site-specific HLS, where it spits out the cabal project for the exe, as well as config info for emacs, vscode etc.

Crazy how things explode.

alanz avatar Dec 21 '20 18:12 alanz

Well, you don't have to put any config for lsp-haskell, really. It's all optional. So I think it's fine to have a host of configuration options there for people who go looking for them, it's not thrust at people who don't care about them.

However, that made me think about another case: as well as totally unknown settings, HLS should tolerate settings it might know about but isn't able to deal with (e.g. for plugins that aren't enabled in your build of HLS). Maybe that will happen automatically, but good to remember it.

michaelpj avatar Dec 23 '20 13:12 michaelpj