RPM support for semantic versioning

Łukasz Stelmach l.stelmach at samsung.com
Thu Nov 6 10:38:02 UTC 2014


It was <2014-11-06 czw 09:40>, when 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?
> 2. If not, can it be added, maybe with an option?

A really bad way to successfully work around this problem is to use the
Epoch field.

-- 
Łukasz Stelmach
Samsung R&D Institute Poland
Samsung Electronics
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 489 bytes
Desc: not available
URL: <http://lists.rpm.org/pipermail/rpm-list/attachments/20141106/978e68cf/attachment.asc>


More information about the Rpm-list mailing list