feat: add rust-tools plugin
This commit is contained in:
parent
f42e3c31b5
commit
5abe595986
2 changed files with 12 additions and 1 deletions
|
@ -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'})
|
||||||
|
|
||||||
|
|
|
@ -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)
|
||||||
|
|
Loading…
Reference in a new issue