30 lines
600 B
Lua
30 lines
600 B
Lua
|
|
local lsp_config = require('nvim-lspconfig')
|
||
|
|
local on_attach = require('lsp/on_attach')
|
||
|
|
|
||
|
|
lsp_config.sumneko_lua.setup({
|
||
|
|
on_attach = on_attach,
|
||
|
|
settings = {
|
||
|
|
Lua = {
|
||
|
|
runtime = {
|
||
|
|
version = 'LuaJIT',
|
||
|
|
},
|
||
|
|
diagnostics = {
|
||
|
|
enable = true,
|
||
|
|
globals = {
|
||
|
|
"vim",
|
||
|
|
"describe",
|
||
|
|
"it",
|
||
|
|
"before_each",
|
||
|
|
"after_each"
|
||
|
|
}
|
||
|
|
},
|
||
|
|
workspace = {
|
||
|
|
library = {
|
||
|
|
[vim.fn.expand('$VIMRUNTIME/lua')] = true,
|
||
|
|
[vim.fn.expand('$VIMRUNTIME/lua/vim/lsp')] = true
|
||
|
|
},
|
||
|
|
},
|
||
|
|
}
|
||
|
|
}
|
||
|
|
})
|