~kaction/config

263a772ea7708b6a9880be7d18dfa35b9eec847a — Dmitry Bogatov 4 months ago 6be5da0
neovim: use git root for haskell LSP

Default configuration looks for cabal file, but I often prefer to use
Nix and ghc directly, skipping cabal.
1 files changed, 4 insertions(+), 1 deletions(-)

M universe/neovim/boot/lua/boot.lua
M universe/neovim/boot/lua/boot.lua => universe/neovim/boot/lua/boot.lua +4 -1
@@ 58,7 58,10 @@ function M.main()
  lspconfig.pyls.setup(opts)
  lspconfig.gopls.setup(opts)
  lspconfig.rnix.setup(opts)
  lspconfig.hls.setup(opts)
  lspconfig.hls.setup {
      on_attach = lsp_on_attach,
      root_dir = lspconfig.util.find_git_ancestor
  }

  vim.lsp.handlers["textDocument/publishDiagnostics"] = vim.lsp.with(
    vim.lsp.diagnostic.on_publish_diagnostics, { virtual_text = false })