port release candidate versioning question

Blair Zajac blair at orcaware.com
Mon Aug 17 18:36:53 UTC 2020



> On Aug 17, 2020, at 11:35 AM, Arno Hautala <arno at alum.wpi.edu> wrote:
> 
>> On 17 Aug 2020, at 13:28, Ken Cunningham <ken.cunningham.webuse at gmail.com> wrote:
>> 
>> ie does macports see versions like this:
>> 
>> 11.0.0 > 11-rc3 > 11-rc2 > 11-rc1 ?
> 
> 
> My understanding is that your example will indeed sort correctly. To verify this, and to test other cases, you can try the ‘vercmp’ script [1]
> 
> [1]: https://github.com/macports/macports-base/blob/master/src/pextlib1.0/tests/vercomp.tcl
> 
> If you do run in to an issue, you can use the ‘epoch’ field to force a sort order. ‘epoch’ is considered an always increasing value. And it being present takes precedence over not being present. Therefore, once you use ‘epoch’ you _can’t_ stop using it. It’s always seemed like a good idea to me to use a date format for this, but it’s not required. Something like YYYYMMDDhhmm (ie. 202008171430) should give enough precision (fingers crossed).
> 

One could also put a leading ‘0.’ in front of the actual version number and then remove it for the final version which would indicate a non-final release.

Blair



More information about the macports-dev mailing list