all repos

init.lua @ b87973847ce849636e2c6f29317dcb77f8c44c68

my nvim config
2 files changed, 10 insertions(+), 7 deletions(-)
feat(lsp): use more default keymaps and unmap those i dont like
Author: Oleksandr Smirnov olexsmir@gmail.com
Committed at: 2025-02-11 18:21:51 +0200
Parent: ce79b28
M lua/core/keymaps.lua

@@ -1,5 +1,15 @@

local u = require "core.utils" +-- i dont want any builtin keymap for my lsp +if vim.fn.has "nvim-0.11" == 1 then + vim.keymap.del("n", "grn") + vim.keymap.del({ "n", "x" }, "gra") + vim.keymap.del("n", "grr") + vim.keymap.del("n", "gri") + vim.keymap.del("n", "gO") + vim.keymap.del({ "i", "s" }, "<C-s>") +end + -- general u.map("n", "<leader>q", "<cmd>quit!<cr>") u.map("n", "<leader>w", "<cmd>write!<cr>")
M lua/plugins/lsp/attach.lua

@@ -18,14 +18,7 @@

u.map("n", "<leader>lf", function() vim.lsp.buf.format { async = true } end, bufnr) - u.map("n", "]d", function() - vim.diagnostic.jump { count = 1, float = false } - end, bufnr) - u.map("n", "[d", function() - vim.diagnostic.jump { count = -1, float = false } - end, bufnr) - u.map("n", "K", vim.lsp.buf.hover, bufnr) u.map("n", "gd", "<cmd>Telescope lsp_definitions<cr>", bufnr) u.map("n", "gr", "<cmd>Telescope lsp_references<cr>", bufnr) u.map("n", "gi", "<cmd>Telescope lsp_implementations<cr>", bufnr)