↧
Answer by Wiktor Stribiżew for RegEx Return found Group IF String Does NOT...
I suggest usingFind What: \{\{[\s\n]*(?!['\s\n])(.*')[\s\n]*(\|[\s\n]+translate)\bReplace With: {{ '$1 $2See online regex demo (altered to reflect how it works in VSCode).Details^ - start of a...
View ArticleAnswer by rollingcodes for RegEx Return found Group IF String Does NOT start...
This should do the trick:Replace\{\{(?:\s|\n)*(?!(?:'|\s|\n))(.*')(?:\s|\n)*(\|(?:\s|\n)+translate)\bwith{{ '$1 $2Regex 101 DemoExplanation:\{\{ - match two open braces(?:\s|\n)* - match any number of...
View ArticleRegEx Return found Group IF String Does NOT start with ' - VSCode -...
So, I did a global undoable RegEx search and replace. I forgot to include the ' in the replace. Now I need to do a search on strings that match the below. It must not start with a ' and will have |...
View Article