From 7e40488298536c5d3b33d1c2351c058329604404 Mon Sep 17 00:00:00 2001 From: Max Bossing Date: Thu, 24 Jul 2025 19:18:27 +0200 Subject: It's all comming together --- nvim/lua/lsp.lua | 8 +++++++- nvim/lua/options.lua | 1 + nvim/lua/plugins.lua | 2 +- 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/nvim/lua/lsp.lua b/nvim/lua/lsp.lua index 3e51c56..6094b2f 100644 --- a/nvim/lua/lsp.lua +++ b/nvim/lua/lsp.lua @@ -3,7 +3,7 @@ require('mason').setup() vim.lsp.enable('lua-language-server') local bufnr = vim.api.nvim_get_current_buf() -vim.keymap.set('n', 'a', +vim.keymap.set('n', 'gra', function() vim.cmd.RustLsp('codeAction') end, @@ -17,6 +17,12 @@ vim.keymap.set('n', 'K', { silent = true, buffer = bufnr } ) +vim.keymap.set('n', 'gd', + function() + vim.cmd.RustLsp({'renderDiagnostic', 'current'}) + end, + { silent = true, buffer = bufnr } +) local cmp = require('cmp') cmp.setup({ diff --git a/nvim/lua/options.lua b/nvim/lua/options.lua index a7cce04..9de7b72 100644 --- a/nvim/lua/options.lua +++ b/nvim/lua/options.lua @@ -33,3 +33,4 @@ vim.o.ruler = true -- Show something in the command line not sure vim.o.showcmd = true +vim.diagnostic.config({ virtual_text = false }) diff --git a/nvim/lua/plugins.lua b/nvim/lua/plugins.lua index 6798980..f1c6367 100644 --- a/nvim/lua/plugins.lua +++ b/nvim/lua/plugins.lua @@ -60,7 +60,7 @@ require("lazy").setup({ }, lazy = false, }, - + -- Markdown { 'OXY2DEV/markview.nvim', -- cgit v1.0