lsp rust tools

This commit is contained in:
Tiago Sousa 2024-10-21 09:51:12 +01:00
parent 3cab45704e
commit ce19e9fcbf
Signed by: tiago
SSH key fingerprint: SHA256:odOD9vln9U7qNe1R8o3UCbE3jkQCkr5/q5mgd5hwua0

View file

@ -136,22 +136,27 @@ return {
}) })
end, end,
}, },
{
"mrcjkb/rustaceanvim",
version = "^5", -- Recommended
lazy = false, -- This plugin is already lazy
},
-- { {
-- "zbirenbaum/copilot.lua", "zbirenbaum/copilot.lua",
-- event = "InsertEnter", event = "InsertEnter",
-- config = function() config = function()
-- require("copilot").setup({ require("copilot").setup({
-- suggestion = { suggestion = {
-- enabled = true, enabled = true,
-- auto_trigger = true, auto_trigger = true,
-- keymap = { keymap = {
-- accept = "<C-q>", accept = "<C-q>",
-- }, },
-- }, },
-- }) })
-- end, end,
-- }, },
{ {
"neovim/nvim-lspconfig", "neovim/nvim-lspconfig",
dependencies = { dependencies = {
@ -219,15 +224,15 @@ return {
local capabilities = local capabilities =
vim.tbl_deep_extend("force", lsp_defaults.capabilities, require("cmp_nvim_lsp").default_capabilities()) vim.tbl_deep_extend("force", lsp_defaults.capabilities, require("cmp_nvim_lsp").default_capabilities())
-- external (non mason) lsps -- external (non mason) lsps
lspconfig.rust_analyzer.setup({ -- lspconfig.rust_analyzer.setup({
capabilities = capabilities, -- capabilities = capabilities,
cmd = { -- cmd = {
"rustup", -- "rustup",
"run", -- "run",
"stable", -- "stable",
"rust-analyzer", -- "rust-analyzer",
}, -- },
}) -- })
require("mason-lspconfig").setup({ require("mason-lspconfig").setup({
ensure_installed = { ensure_installed = {