feat: add <leader>d to duplicate line
This custom duplicate line mapping keeps the cursor in the same column. (Which is useful when duplicating lines and modifying them at the same time)
This commit is contained in:
parent
81b7e9f929
commit
b47494563d
1 changed files with 2 additions and 0 deletions
|
|
@ -31,6 +31,8 @@ vim.keymap.set("n", "<Down>", "<C-w>j")
|
||||||
vim.keymap.set("n", "<Up>", "<C-w>k")
|
vim.keymap.set("n", "<Up>", "<C-w>k")
|
||||||
vim.keymap.set("n", "<Right>", "<C-w>l")
|
vim.keymap.set("n", "<Right>", "<C-w>l")
|
||||||
|
|
||||||
|
-- Duplicate line
|
||||||
|
vim.keymap.set("n", "<leader>d", "mzyyp`zj")
|
||||||
|
|
||||||
-- Open a new terminal pane
|
-- Open a new terminal pane
|
||||||
vim.keymap.set("n", "<leader>t", "<cmd>botright terminal<CR>")
|
vim.keymap.set("n", "<leader>t", "<cmd>botright terminal<CR>")
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue