How to stop LunarVim Mason from automatically installing a language server?

130 Views Asked by At

I am using LunarVim in a Nix environment to program Haskell. The environment has a haskell-language-server of its own, which starts promptly when I open a file by LunarVim. The problem is that after some time, LunarVim's Mason installs its own HLS, which conflicts with the environment's HLS, stopping both from working. I would like to disable Mason's overly-eager installation of the LS somehow.

So far I have tried the following:

Adding the following to init.lua and/or config.lua (or elsewhere in a file linked to in config.lua):

lvim.lsp.automatic_servers_installation = false
lvim.lsp.automatic_configuration.skipped_servers = {"haskell-language-server"}
lvim.lsp.LvimCacheReset()

Enabling and disabling Mason in plugins.lua (linked to in config.lua)

 { "williamboman/mason.nvim",
    require("mason").setup()    },
  {
  { "williamboman/mason-lspconfig.nvim"
  },

Whatever I do, Mason jumps in and installs the hls. How to stop it?

0

There are 0 best solutions below