I'm currently using (['\"])(?:\\1|.*?\\1)
to capture group of quotes.
Text: "Hello", is it 'me youre looking for'?
# result: "Hello" (\1) and 'me youre looking for' (\2)
Additionally I want it to ignore escaped quotes inside those groups (or globally, also fine).
Text: "Hello", is it 'me you\'re looking for'?
# result: "Hello" (\1) and 'me you\'re looking for' (\2)
Using python. I'm aware that this questions is somewhat similar. However, I was unable to apply it to my existing regex.
Thanks, regex freaks!