Datatypes

Semantic version (SemVer)

ID semver

DatatypeNot PIIidentifier

Version number in the Semantic Versioning 2.0.0 format: MAJOR.MINOR.PATCH, optionally followed by a pre-release part after '-' and build metadata after '+'.

Categories
Software development
Countries
Global (not tied to a country)
Languages
Common to most languages
Quality
85/100 · missing: mapping (Wikidata, Schema.org, ...), translation
Metacrafter rules
1 rule (0 by field name, 1 by value)
Supported by tools
metacrafter

Regular expression

^(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?$

Python re syntax.

Examples

ValueDescription
1.0.0release
2.1.3-alpha.1pre-release
1.0.0-rc.1+build.5pre-release with build metadata
1.0 invalidPATCH is missing
01.2.3 invalidleading zero

Sources

Use this record