Regular Expressions 101

Community Patterns

Community Library Entry

0

Regular Expression
PCRE2 (PHP >=7.3)

/
^(\d+\.)(\d+\.)(\*|\d+)$
/
gm

Description

This regex will only allow the Major.Minor.Patch pattern to pass.

Submitted by Rónmag - 2 years ago