dotfiles/neovim/.config/nvim/lua/lsp.lua

21 lines
451 B
Lua
Raw Permalink Normal View History

--Python
local capabilities = vim.lsp.protocol.make_client_capabilities()
capabilities = require('cmp_nvim_lsp').default_capabilities(capabilities)
require('lspconfig').pyright.setup{
capabilities = capabilities,
}
--Terraform
require'lspconfig'.terraformls.setup{}
vim.api.nvim_create_autocmd({"BufWritePre"}, {
pattern = {"*.tf", "*.tfvars"},
callback = function()
vim.lsp.buf.format()
end,
})
--Lua
require'lspconfig'.lua_ls.setup{}