feat: add rust-tools plugin

This commit is contained in:
mandlm 2022-04-08 08:03:34 +02:00
parent f42e3c31b5
commit 5abe595986
Signed by: mandlm
GPG Key ID: 4AA25D647AA54CC7
2 changed files with 12 additions and 1 deletions

View File

@ -193,6 +193,9 @@ return require('packer').startup(function(use)
-- automatic pairs -- automatic pairs
use({"Raimondi/delimitMate"}) use({"Raimondi/delimitMate"})
-- rust tools
use({"simrat39/rust-tools.nvim", requires = {{"neovim/nvim-lspconfig"}}})
-- markdown preview -- markdown preview
use({'iamcco/markdown-preview.nvim'}) use({'iamcco/markdown-preview.nvim'})

View File

@ -142,5 +142,13 @@ lsp_installer.on_server_ready(function(server)
extra_server_opts[server.name](opts) extra_server_opts[server.name](opts)
end end
server:setup(opts) if server.name == "rust_analyzer" then
require("rust-tools").setup({
server = vim.tbl_deep_extend("force", server:get_default_options(),
opts)
})
server:attach_buffers()
else
server:setup(opts)
end
end) end)