From 566b391dcc43d03c0d34390d8d0596f07fe9640c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ensar=20Saraj=C4=8Di=C4=87?= Date: Thu, 21 Nov 2024 17:58:05 +0100 Subject: [PATCH] Add crates.nvim --- symlinks/config/nvim/lua/esensar/init/plugins.lua | 1 + symlinks/config/nvim/lua/esensar/lsp/servers.lua | 12 ++++++++++++ 2 files changed, 13 insertions(+) diff --git a/symlinks/config/nvim/lua/esensar/init/plugins.lua b/symlinks/config/nvim/lua/esensar/init/plugins.lua index 0d89889..64734d5 100644 --- a/symlinks/config/nvim/lua/esensar/init/plugins.lua +++ b/symlinks/config/nvim/lua/esensar/init/plugins.lua @@ -45,6 +45,7 @@ return require("lazy").setup({ "nvim-neotest/nvim-nio", "nvim-neotest/neotest-plenary", "rouge8/neotest-rust", + "saecki/crates.nvim", "nvim-neotest/neotest-vim-test", -- vim-test plugin for neotest "vim-test/vim-test", -- Running tests from vim "mfussenegger/nvim-dap", -- Debug Adapter Protocol diff --git a/symlinks/config/nvim/lua/esensar/lsp/servers.lua b/symlinks/config/nvim/lua/esensar/lsp/servers.lua index c605416..023a3ef 100644 --- a/symlinks/config/nvim/lua/esensar/lsp/servers.lua +++ b/symlinks/config/nvim/lua/esensar/lsp/servers.lua @@ -111,3 +111,15 @@ vim.g.rustaceanvim = { }, }), } + +require("crates").setup({ + lsp = { + enabled = true, + on_attach = function(client, bufnr) + common_config.on_attach(client, bufnr) + end, + actions = true, + completion = true, + hover = true, + }, +})