enabled language servers

This commit is contained in:
Joel Lau 2024-03-01 19:20:05 +08:00 committed by Joel Lau
parent a48d5688e1
commit 9f3c7fcc96
No known key found for this signature in database
GPG Key ID: C2A155B2D3A77578
1 changed files with 11 additions and 1 deletions

View File

@ -720,7 +720,9 @@ require('mason-lspconfig').setup()
local servers = {
-- clangd = {},
gopls = {},
-- pyright = {},
terraformls = {},
sqlls = {},
pyright = {},
-- rust_analyzer = {},
-- tsserver = {},
html = { filetypes = { 'html' } },
@ -760,6 +762,14 @@ mason_lspconfig.setup_handlers {
end,
}
-- format on save (terraform)
vim.api.nvim_create_autocmd({ "BufWritePre" }, {
pattern = { "*.tf", "*.tfvars" },
callback = function()
vim.lsp.buf.format()
end
})
-- [[ Configure nvim-cmp ]]
-- See `:help cmp`
local cmp = require 'cmp'