Like this for Vim, I'm trying to convert (with no success):
matchadd('ColorColumn', '\%81v\s*\zs\S', 100)
from vimscript to a Lua autocmd
:
autocmd({'BufRead'}, {
pattern = "*",
callback = function ()
vim.fn.matchadd('ColorColumn', '\\%81v\\s*\\zs\\S')
end
})
What am I doing wrong?
wo.colorcolumn = "80"
but show column always not only on characters >=81. This autocmd should replace the behavior