diff options
Diffstat (limited to 'modules/neovim/nvim/lua/config/lsp/zls.lua')
| -rw-r--r-- | modules/neovim/nvim/lua/config/lsp/zls.lua | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/modules/neovim/nvim/lua/config/lsp/zls.lua b/modules/neovim/nvim/lua/config/lsp/zls.lua new file mode 100644 index 0000000..d2013a4 --- /dev/null +++ b/modules/neovim/nvim/lua/config/lsp/zls.lua @@ -0,0 +1,11 @@ +return { + cmd = { "zls" }, + filetypes = { "zig", "zir" }, + on_new_config = function(new, old) + if vim.fn.filereadable(vim.fs.joinpath(new_root_dir, "zls.json")) ~= 0 then + new.cmd = { "zls", "--config-path", "zls.json" } + end + end, + root_markers = { "zls.json", "build.zig", ".git" }, + single_file_support = true, +} |