Re: [PATCH] versionsort: support reorder prerelease suffixes
- From
Duy Nguyen <pclouds@gmail.com>
- Date
- Mar 9, 2015, 01:01 UTC
- Message-ID
- <CACsJy8Bpta0rw1rjN8ROcUykPK508bvH_bvAJzLQQa6L6OmH7w@mail.gmail.com>
- In-Reply-To
- <xmqqmw3s5j1y.fsf@gitster.dls.corp.google.com>
On Thu, Mar 5, 2015 at 8:28 AM, Junio C Hamano <gitster@pobox.com> wrote:
Show 26 quoted lines
> Junio C Hamano <gitster@pobox.com> writes: > >>> +versionsort.prereleaseSuffix:: >>> + When version sort is used in linkgit:git-tag[1], prerelease >>> + tags (e.g. "1.0-rc1") may appear after the main release >>> + "1.0". By specifying the suffix "-rc" in this variable, >>> + "1.0-rc1" will appear before "1.0". One variable assignment >>> + per suffix. >> >> I think the last half-sentence want to mean that >> >> [versionsort] >> prereleaseSuffix = -pre >> prereleaseSuffix = -rc >> >> is the supported way to write, and not >> >> [versionsort] >> prereleaseSuffix = -pre -rc >> >> but it probably is unclear unless the reader already knows what it >> is trying to say. The reader also needs to learn somewhere how the >> order of the entries affects the result. > > This is already in 'next', so could you fix that half-sentence in > the documentation via an incremental update?
How about..
".. "1.0-rc1" will appear before "1.0". This key can be specified multiple times, one for each suffix. The order of suffixes in the config file determines the sorting order (e.g. if "-pre" appears before "-rc" in the config file then 1.0-preXX is sorted before 1.0-rcXX). The sorting order between different suffixes is undefined if they are in multiple config files"
-- Duy