mirror of
https://github.com/LazyVim/LazyVim.git
synced 2025-06-23 09:18:51 +02:00
fix(lsp): temp mason fix for sumenko_lua -> lua_ls rename. See #248
This commit is contained in:
parent
57e92b04e2
commit
543126818e
1 changed files with 9 additions and 1 deletions
|
@ -37,7 +37,7 @@ return {
|
|||
---@type lspconfig.options
|
||||
servers = {
|
||||
jsonls = {},
|
||||
sumneko_lua = {
|
||||
lua_ls = {
|
||||
-- mason = false, -- set to false if you don't want this server to be installed with mason
|
||||
settings = {
|
||||
Lua = {
|
||||
|
@ -101,6 +101,14 @@ return {
|
|||
require("lspconfig")[server].setup(server_opts)
|
||||
end
|
||||
|
||||
-- temp fix for lspconfig rename
|
||||
-- https://github.com/neovim/nvim-lspconfig/pull/2439
|
||||
local mappings = require("mason-lspconfig.mappings.server")
|
||||
if not mappings.lspconfig_to_package.lua_ls then
|
||||
mappings.lspconfig_to_package.lua_ls = "lua-language-server"
|
||||
mappings.package_to_lspconfig["lua-language-server"] = "lua_ls"
|
||||
end
|
||||
|
||||
local mlsp = require("mason-lspconfig")
|
||||
local available = mlsp.get_available_servers()
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue