I'm new to VimScript and trying to learn how to construct patterns.
Is there a Vim plugin like RegExr.com for testing patterns?
I'm new to VimScript and trying to learn how to construct patterns.
Is there a Vim plugin like RegExr.com for testing patterns?
There is a very simple way, for which you do not need any plugin. Open a file with some content, turn on :set incsearch
and/or :set hlsearch
and try it out interactively with Vim.
That's how you learn best, using the tools that you have available.
The trace provide you a preview of the substitution and privide a good help to learn regular expression patterns.
If you are using Neovim you could also be interested by hypersonic
:set incsearch
and just trying it out interactively?