Regular Expressions 101

Community Patterns

Conventional Commit Footer

1

Regular Expression
PCRE (PHP <7.3)

/
^(?<token>[\w\-]+|BREAKING CHANGE)(?<seperator>: | #)(?<value>.*?(?=^([\w\-]+|BREAKING CHANGE)(: | #)))
/
gms

Description

Supports multi line value for git trailers with lookahead for beginning of next git trailer

Submitted by Christos Cunning - 3 years ago