Overwrite 'c' ('change') keybinding so it leaves yank register alone
This commit is contained in:
parent
4a2cc0c04f
commit
1260a4957d
5
init.lua
5
init.lua
|
@ -1217,6 +1217,11 @@ vim.diagnostic.config {
|
||||||
|
|
||||||
vim.keymap.set('', '<Leader>l', require('lsp_lines').toggle, { desc = 'Toggle lsp_lines' })
|
vim.keymap.set('', '<Leader>l', require('lsp_lines').toggle, { desc = 'Toggle lsp_lines' })
|
||||||
|
|
||||||
|
-- Redirect change operations to the blackhole to avoid spoiling 'y' register content
|
||||||
|
-- https://www.reddit.com/r/neovim/comments/13p5mq7/comment/jl824ti
|
||||||
|
vim.keymap.set('', 'c', '"_c')
|
||||||
|
vim.keymap.set('', 'C', '"_C')
|
||||||
|
|
||||||
-- You can link highlighting groups.
|
-- You can link highlighting groups.
|
||||||
-- This is the default (when colour scheme is unknown)
|
-- This is the default (when colour scheme is unknown)
|
||||||
-- Try with CursorColumn, Pmenu, Folded etc.
|
-- Try with CursorColumn, Pmenu, Folded etc.
|
||||||
|
|
Loading…
Reference in New Issue