1
0

Yank to clipboard explicitly

Prevents the clipboard from being spammed with yanked content
This commit is contained in:
Patrick Auernig 2024-06-05 16:04:27 +02:00
parent b60f0c8457
commit ad09e704e8
2 changed files with 10 additions and 9 deletions

View File

@ -6,6 +6,10 @@ map("n", "Y", "y$")
map({ "n", "v", "i" }, "<C-s>", "<cmd>w<CR>") map({ "n", "v", "i" }, "<C-s>", "<cmd>w<CR>")
map("n", "s", "<NOP>") map("n", "s", "<NOP>")
-- Yank to clipboard
map({ "n", "v" }, "<Leader>y", [["+y]])
map({ "n", "v" }, "<Leader>Y", [["+Y]])
-- Move up and down visual lines for the few times I need wrapping -- Move up and down visual lines for the few times I need wrapping
map("n", "j", "gj") map("n", "j", "gj")
map("n", "k", "gk") map("n", "k", "gk")

View File

@ -20,9 +20,6 @@ vim.opt.foldlevelstart = 99
vim.opt.fillchars:append({ eob = "·" }) vim.opt.fillchars:append({ eob = "·" })
-- yank to clipboard, requires wl-copy command or equivalent
vim.opt.clipboard:append("unnamedplus")
vim.g.mapleader = " " vim.g.mapleader = " "