From: Xinglu Chen <public@yoctocell.xyz>
To: Nicolas Goaziou <mail@nicolasgoaziou.fr>
Cc: 48667@debbugs.gnu.org
Subject: [bug#48667] [PATCH] doc: Expound on how to specify the version of a package.
Date: Wed, 26 May 2021 16:07:55 +0200 [thread overview]
Message-ID: <874kepy4ec.fsf@yoctocell.xyz> (raw)
In-Reply-To: <87tumphcey.fsf@nicolasgoaziou.fr>
[-- Attachment #1: Type: text/plain, Size: 2323 bytes --]
On Wed, May 26 2021, Nicolas Goaziou wrote:
> Hello,
>
> Xinglu Chen <public@yoctocell.xyz> writes:
>
>> * doc/guix.texi (package Reference): Describe how packages that lack a release
>> or are pinned to an unreleased version should specify the ‘version’ field.
>> Add documentation for the ‘git-version’ procedure.
>
> Thanks.
>
> I don't know if all should be included in the manual (though I think
> the `git-version' function definitely should), but I'll comment it a bit
> anyway.
>
>> @item @code{version}
>> -The version of the package, as a string.
>> +The version of the package, as a string. If there are no releases of
>> +the package, or a unreleased version is desired, the version should
>> +contain @code{VERSION-REVISION.COMMIT}. @code{VERSION} is
>> +@c TODO: 0.0.0 or just 0 ?
>
> @samp{@var{VERSION}-@var{REVISION}.@var{COMMIT}} ... @var{VERSION}...
>
> I think you should drop the "version 0" case altogether. I don't think
> enforcing "0" or "0.0.0" does matter, and it adds noise to the
> explanations.
Makes sense, users can probably that out on their own.
>> +@code{0.0.0} or whatever the latest version is, and @code{REVISION} is
>> +the revision of the Guix package (@code{0} if it is a new package),
>> +whenever the package is updated to a newer version the revision should
>> +also be bumped.
>
> @var{REVISION}
>
> I think you need to explain why bumping revision is needed.
>
> Also, this is all specific to hash-based repositories. For example, SVN
> uses monotonic revisions already, so none of the above applies to such
> packages.
I am not familiar with SVN, but I will look into it.
>> @code{COMMIT} is the @dfn{commit} or @dfn{changeset}
>> +corresponding to the version, it should only contain 7 characters. If
>> +the fetch method is @code{git-fetch} (@pxref{origin Reference}), there
>> +is the @code{git-version} procedure that makes it easier to specify the
>> +version.
>
> @var{COMMIT}
>
>> +@example
>> +(git-version "0.0.0" "0" "93818c936ee7e2f1ba1b315578bde363a7d43d05")
>> +@result{} "0.0.0-0.93818c9"
>> +@end example
>> +@end deffn
>
> Here too, I think the special "0.0.0" case is misleading.
>
> Maybe @lisp is more appropriate than @example.
Good point.
Thanks for the review!
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 861 bytes --]
next prev parent reply other threads:[~2021-05-26 14:17 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-05-26 9:00 [bug#48667] [PATCH] doc: Expound on how to specify the version of a package Xinglu Chen
2021-05-26 13:06 ` Nicolas Goaziou
2021-05-26 14:07 ` Xinglu Chen [this message]
2021-05-26 14:57 ` Xinglu Chen
2021-06-05 20:29 ` Ludovic Courtès
2021-06-06 9:09 ` Xinglu Chen
2021-06-06 9:19 ` [bug#48667] [PATCH] doc: Add reference for ‘git-ver Xinglu Chen
2021-06-06 9:48 ` Maxime Devos
2021-06-06 10:33 ` Xinglu Chen
2021-06-06 10:37 ` [bug#48667] [PATCH v2] doc: Add refernece for ‘git-version’ and ‘hg-version’ Xinglu Chen
2021-06-06 12:36 ` bug#48667: " Ludovic Courtès
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://guix.gnu.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=874kepy4ec.fsf@yoctocell.xyz \
--to=public@yoctocell.xyz \
--cc=48667@debbugs.gnu.org \
--cc=mail@nicolasgoaziou.fr \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/guix.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).