From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id qO7jNP5HrmAjZAAAgWs5BA (envelope-from ) for ; Wed, 26 May 2021 15:07:10 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id ABB+MP5HrmDLNQAAbx9fmQ (envelope-from ) for ; Wed, 26 May 2021 13:07:10 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 2B893270BC for ; Wed, 26 May 2021 15:07:10 +0200 (CEST) Received: from localhost ([::1]:52358 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lltFc-0006Wo-Om for larch@yhetil.org; Wed, 26 May 2021 09:07:08 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:48436) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lltFW-0006U0-2l for guix-patches@gnu.org; Wed, 26 May 2021 09:07:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:36357) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lltFV-0007i7-RR for guix-patches@gnu.org; Wed, 26 May 2021 09:07:01 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1lltFV-0003hA-Jo for guix-patches@gnu.org; Wed, 26 May 2021 09:07:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#48667] [PATCH] doc: Expound on how to specify the version of a package. Resent-From: Nicolas Goaziou Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Wed, 26 May 2021 13:07:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 48667 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Xinglu Chen Cc: 48667@debbugs.gnu.org Received: via spool by 48667-submit@debbugs.gnu.org id=B48667.162203441614192 (code B ref 48667); Wed, 26 May 2021 13:07:01 +0000 Received: (at 48667) by debbugs.gnu.org; 26 May 2021 13:06:56 +0000 Received: from localhost ([127.0.0.1]:47903 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lltFQ-0003gq-71 for submit@debbugs.gnu.org; Wed, 26 May 2021 09:06:56 -0400 Received: from relay7-d.mail.gandi.net ([217.70.183.200]:47969) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lltFO-0003gb-9w for 48667@debbugs.gnu.org; Wed, 26 May 2021 09:06:55 -0400 Received: (Authenticated sender: admin@nicolasgoaziou.fr) by relay7-d.mail.gandi.net (Postfix) with ESMTPSA id 3409820017; Wed, 26 May 2021 13:06:46 +0000 (UTC) From: Nicolas Goaziou References: <06217762b07f95d2ba2d40277d010647a926df68.1622019402.git.public@yoctocell.xyz> Date: Wed, 26 May 2021 15:06:45 +0200 In-Reply-To: <06217762b07f95d2ba2d40277d010647a926df68.1622019402.git.public@yoctocell.xyz> (Xinglu Chen's message of "Wed, 26 May 2021 11:00:25 +0200") Message-ID: <87tumphcey.fsf@nicolasgoaziou.fr> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1622034430; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post; bh=7ZwDgs/RMOhel9AJIi608FVfWLebCR76dNzYRlJ2vZ0=; b=gJhP/Ba6S3LboJDtNsWjTKWSBEoxHNZW5D470el45/9gNvVW480IUM3+ukF3KXnkbGQnOp cHx+nFMfaNXtubxmex5fJvyFbMbYN9K35022HgdgeesYxWQYN8G8UcfHcWX6X6YPM3TJes r7iTui6T0BTJyPQWKqVKi7AOO5KjZ/+l19D4nYl8LyLJZaHu4hHphL2KckYOH1gCDHRFZe TxMDCFSQRhSwdBqEzbMVHltY3KieB1ufJAK7855pdUbp7iM9cjAc7HchuSJxEfVUPSghf1 5LE5RvTccLBe0GkDZS/uYfHZ0J0dt/EewahOyTjvBfsMUOPa4rcvdtXRZpV+Ww== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1622034430; a=rsa-sha256; cv=none; b=oDukvou2ahONGmnsQ56J8ig9ZG/Ke4ErhTeZvzkBrRND6Nrv/A7FsCXVNJbtWIl3bFhF+X qSowTm1rHHRIoL6OPR8rR9r28/Vl68F+kE0PdQBRpycbCtkQ5mzSDm3uuHug2NYqwlfhsr meFukxVNmeL/uK/avoj9NMGrNvkQxyGp/zMmWUFYelUE3YABsrU+YmPg9ITrylJqW6yQz+ Ee4BwlMTxPYqDc/vaQb4m8derc5wH/RGHu1OUMAwMJvTgP6J5hp0V5ibGcLbJMH7xz6vWQ cLP3YVF4l/5dvdtPorOEPKu2Ja7930uw4miLGHVp2MveNimy2M9tqH35f92ypA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Spam-Score: -2.43 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Queue-Id: 2B893270BC X-Spam-Score: -2.43 X-Migadu-Scanner: scn0.migadu.com X-TUID: +3onteN2aQBw Hello, Xinglu Chen writes: > * doc/guix.texi (package Reference): Describe how packages that lack a re= lease > or are pinned to an unreleased version should specify the =E2=80=98versio= n=E2=80=99 field. > Add documentation for the =E2=80=98git-version=E2=80=99 procedure. Thanks.=20 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. > +@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. > @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. Regards, --=20 Nicolas Goaziou