^start of line
\s*any whitespace character, repeated any number of times
Non-Capturing Group(?:(?:kind(?:est)* )*regards?|cheers?|greetings?|thanks|thank you) 1st Alternative(?:kind(?:est)* )*regards? Non-Capturing Group(?:kind(?:est)* )* *repeats the group contents below any number of times:
kindthe literal text kind (case insensitive) Non-Capturing Group(?:est)* *repeats the group contents below any number of times:
estthe literal text est (case insensitive) the literal (3210 / 408 / 2016)
regardthe literal text regard (case insensitive) s?optionally matches the literal s (11510 / 1638 / 7316) (case insensitive)
cheerthe literal text cheer (case insensitive) s?optionally matches the literal s (11510 / 1638 / 7316) (case insensitive)
3rd Alternativegreetings? greetingthe literal text greeting (case insensitive) s?optionally matches the literal s (11510 / 1638 / 7316) (case insensitive)
thanksthe literal text thanks (case insensitive) thank youthe literal text thank you (case insensitive) \ban ASCII word boundary
,?optionally matches the literal , (4410 / 548 / 2C16)
.*any character (except for line terminators), repeated any number of times
Character Class[\r\n]{0,2} {0,2}matches between 0 and 2 characters from the set below:
\ra carriage return (ASCII 13)
\na line-feed (newline) character (ASCII 10)
.*any character (except for line terminators), repeated any number of times
Non-Capturing Group(?:[.!?: ]*|$) *matches any number of characters from the set below:
.the literal . (4610 / 568 / 2E16)
!the literal ! (3310 / 418 / 2116)
?the literal ? (6310 / 778 / 3F16)
:the literal : (5810 / 728 / 3A16)
the literal (3210 / 408 / 2016)
g modifier: global. Finds all matches instead of stopping after the first
i modifier: insensitive. Matches without distinguishing uppercase and lowercase letters
m modifier: multiline. Causes ^ and $ to match the start and end of each line, not only the start and end of the string