^start of line
=separator=the literal text =separator= (case sensitive) .*any character (except for line terminators), repeated any number of times
Non-Capturing Group(?:\R(?!(?:=separator=|.*?\bunwantedKeyword\b)).*)* *repeats the group contents below any number of times:
\Ra newline sequence
Negative Lookahead(?!(?:=separator=|.*?\bunwantedKeyword\b)) Non-Capturing Group(?:=separator=|.*?\bunwantedKeyword\b) 1st Alternative=separator= =separator=the literal text =separator= (case sensitive) 2nd Alternative.*?\bunwantedKeyword\b .*?any character (except for line terminators), repeated any number of times
\ban ASCII word boundary
unwantedKeywordthe literal text unwantedKeyword (case sensitive) \ban ASCII word boundary
.*any character (except for line terminators), repeated any number of times
\Ra newline sequence
.*?any character (except for line terminators), repeated any number of times
\ban ASCII word boundary
unwantedKeywordthe literal text unwantedKeyword (case sensitive) \ban ASCII word boundary
.*any character (except for line terminators), repeated any number of times
\R*a newline sequence, repeated any number of times
g modifier: global. Finds all matches instead of stopping after the first
m modifier: multiline. Causes ^ and $ to match the start and end of each line, not only the start and end of the string