mirror of
https://github.com/cole-maxwell1/dotfiles.git
synced 2026-01-25 14:40:22 -05:00
35 lines
715 B
Lua
35 lines
715 B
Lua
local lsp_zero = require('lsp-zero')
|
|
|
|
|
|
lsp_zero.on_attach(function(client, bufnr)
|
|
-- see :help lsp-zero-keybindings
|
|
-- to learn the available actions
|
|
lsp_zero.default_keymaps({buffer = bufnr})
|
|
end)
|
|
|
|
lsp_zero.set_sign_icons({
|
|
error = '✘',
|
|
warn = '▲',
|
|
hint = '⚑',
|
|
info = '»'
|
|
})
|
|
|
|
-- to learn how to use mason.nvim
|
|
-- read this: https://github.com/VonHeikemen/lsp-zero.nvim/blob/v3.x/doc/md/guide/integrate-with-mason-nvim.md
|
|
require('mason').setup({})
|
|
require('mason-lspconfig').setup({
|
|
ensure_installed = {
|
|
'lua_ls',
|
|
'tsserver',
|
|
'eslint',
|
|
'gopls',
|
|
'rust_analyzer',
|
|
|
|
},
|
|
handlers = {
|
|
function(server_name)
|
|
require('lspconfig')[server_name].setup({})
|
|
end,
|
|
},
|
|
})
|