From eedc2e1d1b4babca640223a669f2f5b3947632be Mon Sep 17 00:00:00 2001 From: Rob Watson Date: Tue, 28 Feb 2023 17:18:28 +0100 Subject: [PATCH] nvimrc: Update lua_ls config --- nvimrc | 17 ++++------------- 1 file changed, 4 insertions(+), 13 deletions(-) diff --git a/nvimrc b/nvimrc index 674b868..56dcccf 100644 --- a/nvimrc +++ b/nvimrc @@ -844,24 +844,15 @@ nvim_lsp.diagnosticls.setup{ -- Lua -local system_name -if vim.fn.has("mac") == 1 then - system_name = "macOS" -elseif vim.fn.has("unix") == 1 then - system_name = "Linux" -else - print("Unsupported system for sumneko") -end - -local sumneko_root_path = os.getenv("HOME").."/dev/lua-language-server" -local sumneko_binary = sumneko_root_path.."/bin/"..system_name.."/lua-language-server" +local lua_ls_root_path = os.getenv("HOME").."/dev/lua-language-server" +local lua_ls_binary = lua_ls_root_path.."/bin/lua-language-server" local runtime_path = vim.split(package.path, ';') table.insert(runtime_path, "lua/?.lua") table.insert(runtime_path, "lua/?/init.lua") -nvim_lsp.sumneko_lua.setup { - cmd = {sumneko_binary, "-E", sumneko_root_path .. "/main.lua"}; +nvim_lsp.lua_ls.setup { + cmd = {lua_ls_binary, "-E", lua_ls_root_path .. "/main.lua"}; settings = { Lua = { runtime = {