DevToys
DevToys copied to clipboard
Add support for Perl regexes
Is your feature request related to a problem? Please describe. I like the Regex Tester, but it could be much more powerful if support was added for Perl regexes. One feature I find really useful in Perl regexes is the ability to define named subexpressions, because they can be grouped together in one place and then used several times (even recursively) in the same regex.
Example
(?(DEFINE)(?<an>[0-9A-Za-z]+))(?&an)_(?&an)_(?&an) should match 05aQ_4rY_dZ0m75.
Note
This is different from reusing capture groups. ([0-9A-Za-z]+)_\1_\1 would match 05aQ_05aQ_05aQ, but not 05aQ_4rY_dZ0m75.
Describe alternatives you've considered Using grep, regex101 (which can use PCRE/PCRE2) or Notepad++ (which uses Boost.Regex).
Additional context If it helps in any way, PowerToys' PowerRename also uses the Boost.Regex library (togglable) for this.
Hello,
Thank you very much for sharing this! It sounds like a fine addition.
Closing as no upvote/traction on this issue. This tool be made as an extension using our SDK: https://devtoys.app/doc