remember to enable lsp
This commit is contained in:
@@ -16,7 +16,7 @@ require("fidget").setup({
|
||||
|
||||
require('mason').setup({})
|
||||
require('mason-lspconfig').setup({
|
||||
ensure_installed = {'bashls', 'clangd', 'marksman', 'pylsp', 'ruff', 'texlab'},
|
||||
ensure_installed = { 'bashls', 'clangd', 'lua_ls', 'marksman', 'pylsp', 'ruff', 'texlab' },
|
||||
automatic_enable = false,
|
||||
})
|
||||
require('mason-nvim-dap').setup({
|
||||
@@ -27,6 +27,7 @@ require('dap-python').setup("python")
|
||||
local servers = {
|
||||
bashls = {},
|
||||
clangd = {},
|
||||
lua_ls = {},
|
||||
marksman = {},
|
||||
pylsp = {
|
||||
settings = {
|
||||
@@ -124,6 +125,8 @@ local on_attach = function(_client, buffer_number)
|
||||
-- Use Prettier to format TS/JS if it's available
|
||||
return format_client.name ~= "tsserver" or not null_ls.is_registered("prettier")
|
||||
end,
|
||||
async = false,
|
||||
timeout_ms = 10000,
|
||||
})
|
||||
end, { desc = "LSP: Format current buffer with LSP" })
|
||||
end
|
||||
@@ -138,6 +141,7 @@ for name, config in pairs(servers) do
|
||||
settings = config.settings,
|
||||
init_options = config.init_options,
|
||||
})
|
||||
vim.lsp.enable(name)
|
||||
end
|
||||
|
||||
vim.diagnostic.config({
|
||||
|
||||
Reference in New Issue
Block a user