Commit 6d7dfc09 authored by Jan Hensel's avatar Jan Hensel 🐧
Browse files

nvim: Set up Lua LSP

parent 10c4f522
......@@ -20,12 +20,29 @@ lspconfig.bashls.setup{}
lspconfig.pylsp.setup{}
-- local luadev = require("lua-dev").setup{
-- lspconfig = {
-- cmd = {"lua-language-server"}
-- },
-- }
-- lspconfig.sumneko_lua.setup{luadev}
local runtime_path = vim.split(package.path, ';')
table.insert(runtime_path, "lua/?.lua")
table.insert(runtime_path, "lua/?/init.lua")
lspconfig.sumneko_lua.setup {
settings = {
Lua = {
telemetry = { enable = false, }, -- 😠
runtime = {
-- Tell the language server which version of Lua you're using (most likely LuaJIT in the case of Neovim)
version = 'LuaJIT',
path = runtime_path,
},
diagnostics = {
-- Get the language server to recognize the `vim` global
globals = {'vim'},
},
workspace = {
-- Make the server aware of Neovim runtime files
library = vim.api.nvim_get_runtime_file("", true),
},
},
},
}
lspconfig.clangd.setup{
init_options = { clangdFileStatus = true },
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment