mirror of
https://github.com/semver/semver.git
synced 2026-07-11 03:53:53 -05:00
[GH-ISSUE #709] Support multi-version specifiers (a.k.a. post release/packaging markers) #5600
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @yajo on GitHub (Jun 9, 2021).
Original GitHub issue: https://github.com/semver/semver/issues/709
Hello. I like semver, but I miss something that marks a post-release.
Why? Well, there are some projects that are just based on an upstream project, and their versions depend on upstream's. One simple example is almost any package on any linux distro. Examples:
1.2.3-1ubuntu3, meaning "upstream version 1.2.3, debian version 1, ubuntu version 3".1.18.6+k3s3meaning "Kubernetes version 1.18.6 with 3rd k3s version".As you can see, the k3s case is abusing the build metadata feature to actually produce a new version with higher precedence, while semver 2.0.0 declares that build metadata should be ignored for precedence.
IMHO this is a valid use case.
My proposal is that we pick up a character (I suggest
&, but/or|or:should be good too) to separate post-release markers. The format for the above package example would look like:For k3s:
Or, for a more complete example:
Well, that's ugly, but you get the point:
&is encountered, it is followed by an alphanumeric identifier that marks the section.., the following is another valid semver specifier.&a.0.0.0.For example, from lower to higher:
@ljharb commented on GitHub (Jun 9, 2021):
It sounds like you want a separate versioning system. This isn't what semver is - there's only one version. Things should not be packaged by "not the software author" - the versioned release IS the ultimate and only package that matters.
@alexandrtovmach commented on GitHub (Jun 14, 2021):
closing in favor of https://github.com/semver/semver/issues/703#issuecomment-841420754