Regular Expressions 101

Community Patterns

SemVer with Tags

0

Regular Expression
PCRE (PHP <7.3)

/
^(?P<major>|[0-9]+)\.(?P<minor>[0-9]+)\.(?P<patch>|[0-9]+)-(?:(?P<GA>GA$)|(?P<PRO>PRO$)|(?P<SNAPSHOT>SNAPSHOT$)|(?P<RC>RC$))$
/
gm

Description

SemVer with Tags

Submitted by Umair Malik - 2 years ago