Re: RPM support for semantic versioning

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 11/06/2014 10:40 AM, Andreas Maier wrote:

Hi,
Apologies if this has been discussed before, but I did not find it using
G**gle... So here we go:

I would like to use semantic versioning (see http://semver.org/) in a
package. One particular definition in semantic versioning is that of a
"pre-release". Quoting from its web page:

    9. A pre-release version MAY be denoted by appending a hyphen and a
       series of dot separated identifiers immediately following the patch
       version. Identifiers MUST comprise only ASCII alphanumerics and
       hyphen [0-9A-Za-z-]. Identifiers MUST NOT be empty. Numeric
       identifiers MUST NOT include leading zeroes. Pre-release versions
       have a lower precedence than the associated normal version. A
       pre-release version indicates that the version is unstable and might
       not satisfy the intended compatibility requirements as denoted by its
       associated normal version. Examples: 1.0.0-alpha, 1.0.0-alpha.1,
       1.0.0-0.3.7, 1.0.0-x.7.z.92.

According to this definition, a pre-version "1.2.3-beta.1" is *older* than
the normal version "1.2.3".

However, RPM considers that pre-version to be *younger* than the normal
version.

RPM instead supports the tilde to denote pre-versions, so "1.2.3~beta.1" is
considered older than "1.2.3".

My questions are:
1. Is there support in RPM today, for correctly treating pre-versions
according to the semantic versioning definition?

No. In rpm (and dpkg as well), the hyphen is the delimiter character between name, version and release components and thus entirely illegal in version.

Note that rpm and dpkg predate semantic version spec by more than a decade AFAICT so "correct" is entirely in the eye of the beholder.

2. If not, can it be added, maybe with an option?

Highly unlikely, the use of '-' in semantic versioning is a world-breaker in dpkg/rpm land already.

	- Panu -

_______________________________________________
Rpm-list mailing list
Rpm-list@xxxxxxxxxxxxx
http://lists.rpm.org/mailman/listinfo/rpm-list




[Index of Archives]     [RPM Ecosystem]     [Linux Kernel]     [Red Hat Install]     [PAM]     [Red Hat Watch]     [Red Hat Development]     [Red Hat]     [Gimp]     [Yosemite News]     [IETF Discussion]

  Powered by Linux