19 lines
498 B
Lua
19 lines
498 B
Lua
local lsp = require('lsp-zero').preset({})
|
|
|
|
vim.diagnostic.config({
|
|
virtual_text = true
|
|
})
|
|
|
|
lsp.on_attach(function(client, bufnr)
|
|
lsp.default_keymaps({buffer = bufnr})
|
|
-- Set tagfunc back to empty instead of vim.lsp.tagfunc(),
|
|
-- to use default tag jumping behaviour withouth going through the lsp.
|
|
-- - see https://neovim.io/doc/user/lsp.html
|
|
vim.opt.tagfunc = ""
|
|
end)
|
|
|
|
-- (Optional) Configure lua language server for neovim
|
|
require('lspconfig').lua_ls.setup(lsp.nvim_lua_ls())
|
|
|
|
lsp.setup()
|