update to neovim 0.6
This commit is contained in:
parent
c9ff0abbc2
commit
1967463cf7
3 changed files with 22 additions and 5 deletions
|
|
@ -7,8 +7,21 @@ local nvim_lsp = require'lspconfig'
|
|||
local on_attach = function(client)
|
||||
end
|
||||
|
||||
local rust_capabilities = vim.lsp.protocol.make_client_capabilities()
|
||||
rust_capabilities.textDocument.completion.completionItem.snippetSupport = true
|
||||
rust_capabilities.textDocument.completion.completionItem.resolveSupport = {
|
||||
properties = {
|
||||
'documentation',
|
||||
'detail',
|
||||
'additionalTextEdits',
|
||||
}
|
||||
}
|
||||
|
||||
-- Enable rust_analyzer
|
||||
nvim_lsp.rust_analyzer.setup({ on_attach=on_attach })
|
||||
nvim_lsp.rust_analyzer.setup({
|
||||
on_attach=on_attach,
|
||||
capabilities=rust_capabilities,
|
||||
})
|
||||
nvim_lsp.gopls.setup({ on_attach=on_attach })
|
||||
nvim_lsp.pyright.setup({ on_attach=on_attach })
|
||||
nvim_lsp.clangd.setup({ on_attach=on_attach })
|
||||
|
|
@ -41,6 +54,9 @@ nvim_lsp.efm.setup {
|
|||
},
|
||||
python = {
|
||||
{ formatCommand = 'black --quiet -', formatStdin = true }
|
||||
},
|
||||
rust = {
|
||||
{ formatCommand = 'rustfmt', formatStdin = true }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -169,7 +185,7 @@ require('lspkind').init({
|
|||
})
|
||||
|
||||
require('trouble').setup {
|
||||
mode = "lsp_document_diagnostics",
|
||||
mode = "document_diagnostics",
|
||||
auto_close = true,
|
||||
action_keys = { -- key mappings for actions in the trouble list
|
||||
-- map to {} to remove a mapping, for example:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue