actions-marketplace-validations/Version Extractor

Extract and parse a semantic version from a tag, ref, or manual input.

View on GitHub

Trust Signals

Scorecard Score
not yet scored
Maintenance Recency
Stale
License
None
namedescriptionrequireddefault
tagTag to extract version from (e.g. v1.3.0). Takes priority over fallback-ref.no""
fallback-refFallback ref name when tag is emptyno${{ github.ref_name }}
prefixVersion prefix to strip (e.g. v)nov
strictWhether to strictly validate semver formatnotrue
extract-patternRegex to extract version from raw input (first capture group is used if present)no""
fail-on-errorWhether to fail the action when version extraction failsnotrue
namedescription
foundWhether a valid version was found (true/false)
sourceThe raw input string before any processing
versionFull version string with prefix (e.g. v1.3.0)
version-numberVersion string without prefix (e.g. 1.3.0)
majorMajor version number
minorMinor version number
patchPatch version number
prereleasePrerelease identifier (if any)
is-prereleaseWhether the version is a prerelease (true/false)