dotfiles/home/.config/nvim/lua/highlight_yank.lua

13 lines
276 B
Lua
Raw Normal View History

2022-11-09 09:01:45 +02:00
-- Highlight yanked text
local ag = vim.api.nvim_create_augroup
local au = vim.api.nvim_create_autocmd
au('TextYankPost', {
group = ag('yank_highlight', {}),
pattern = '*',
callback = function()
vim.highlight.on_yank { higroup='IncSearch', timeout=300 }
end,
})