From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp11.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id QADGDQlu1WH+RAEAgWs5BA (envelope-from ) for ; Wed, 05 Jan 2022 11:08:09 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp11.migadu.com with LMTPS id 6C4fCwlu1WEhKgAA9RJhRA (envelope-from ) for ; Wed, 05 Jan 2022 11:08:09 +0100 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 DD116F0ED for ; Wed, 5 Jan 2022 11:08:08 +0100 (CET) Received: from localhost ([::1]:60872 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n53DE-0004nU-0v for larch@yhetil.org; Wed, 05 Jan 2022 05:08:08 -0500 Received: from eggs.gnu.org ([209.51.188.92]:59002) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n53D8-0004n7-F6 for guix-patches@gnu.org; Wed, 05 Jan 2022 05:08:04 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:56303) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1n53D8-0001F0-5o for guix-patches@gnu.org; Wed, 05 Jan 2022 05:08:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1n53D7-0004Un-Rj for guix-patches@gnu.org; Wed, 05 Jan 2022 05:08:01 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#50072] [PATCH WIP 0/4] Add upstream updater for git-fetch origins. Resent-From: Maxime Devos Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Wed, 05 Jan 2022 10:08:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 50072 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: zimoun Cc: Sarah Morgensen , 50072@debbugs.gnu.org Received: via spool by 50072-submit@debbugs.gnu.org id=B50072.164137723517221 (code B ref 50072); Wed, 05 Jan 2022 10:08:01 +0000 Received: (at 50072) by debbugs.gnu.org; 5 Jan 2022 10:07:15 +0000 Received: from localhost ([127.0.0.1]:39616 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n53CN-0004Th-EM for submit@debbugs.gnu.org; Wed, 05 Jan 2022 05:07:15 -0500 Received: from michel.telenet-ops.be ([195.130.137.88]:59924) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n53CL-0004TW-H4 for 50072@debbugs.gnu.org; Wed, 05 Jan 2022 05:07:14 -0500 Received: from ptr-bvsjgyhxw7psv60dyze.18120a2.ip6.access.telenet.be ([IPv6:2a02:1811:8c09:9d00:3c5f:2eff:feb0:ba5a]) by michel.telenet-ops.be with bizsmtp id ey7B2600H4UW6Th06y7CKh; Wed, 05 Jan 2022 11:07:12 +0100 Message-ID: <52e7be94d926aa06c2a0132090e8c212381e7900.camel@telenet.be> From: Maxime Devos Date: Wed, 05 Jan 2022 11:07:06 +0100 In-Reply-To: <867dbfcf9n.fsf_-_@gmail.com> References: <20220104200643.43374-1-maximedevos@telenet.be> <20220104200643.43374-2-maximedevos@telenet.be> <867dbfcf9n.fsf_-_@gmail.com> Content-Type: multipart/signed; micalg="pgp-sha512"; protocol="application/pgp-signature"; boundary="=-K0kdrlY7wUTtQSQn9jfZ" User-Agent: Evolution 3.38.3-1 MIME-Version: 1.0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telenet.be; s=r22; t=1641377232; bh=nKKd+dR69zkBc3O718gcGXeHQfPTkAOiQdoxFzF2so4=; h=Subject:From:To:Cc:Date:In-Reply-To:References; b=I4xSLBinmkOGdnZN61ReikSu9XVBk+IjLnQijTLY1MgxJgljbo6d+/X3fyI58aJPA RomE0Q30v2lZ8fHCVcsgD9Dk8ocbQc0lvqXipe7arrXlcTG+P7deyzH2VlhRFKxMfD jgyxUeerDQIiWLi2g+Cdh64Vv1ptdg4dT/soJEUrtLUe2mqMCMRXCbIOGKucZg0kID 25PqiTloizppeN4FNAgMJW70NUNLir+AvCkqcHG2BRyp5PKAcvkPsqqOt7gNIpYy0M +gjgOImCkq1Fo7BClFVSU/wb+HRPJjfc9Ls/+gJJuI8doVmXvFtPtKLwElNWTUoAPp m2LaBz6KTqfYg== 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 X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1641377288; 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: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: dkim-signature; bh=nKKd+dR69zkBc3O718gcGXeHQfPTkAOiQdoxFzF2so4=; b=oytd8oKPRY6HquN/SgZW6xkpYSKdnnTCIaWlJLO/5kXv7ROBxjwN1EdW2h28A0sd+7EyKw yrYt8NRY9lBTX2D1Ohhqpj1+/T1DZy9VA1N0PieG879OEavTRi09cVYxNWYL37Cf0Nh/xX 6kGs1owNnnq818JHmWJucNQYcAZOY7M+n9UlZv+LcZVSGhFUMYAOGqZ2498JD2cm6PR/WK yxhW5L2Vc4cMm8nI3r23OGZD+AwnY05yE3K7fTKLS0GiQryHQZEObXIv9TsvO6WKwnYuMo gHxsAy6MN51MSb7Igz4CvN9o6pvvg+GkIiZWrjRlhJK1rX/VOB2jpHmfC2oufQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1641377288; a=rsa-sha256; cv=none; b=ePeRIkV2St81m+0nCcSwxDWkFePwLPB2/vyMu7V69AI4JqYCbhZlNUfvU8CF67HI8g5Le1 AfstE+VA1ehFQuNUL44lxLAW16WcFMRhe3tCq0dboQ6BFBl4n+ygDf29SvBTuCGGRvxaq2 nBOwaNzZvXjhkLikARbbSfVszeuZoN/Ssklmg1v0R3lYpOnK9nMU5GghcxTuM6MKN2uW1k ceOP9Lc+zY8csuGk9eCbt6DRoDHNS/gpP1pBsZ033SpCEVugxvMhxB0BNakB2QlZ7FQGOr o4Alm56m4r3C4i3GqlfhvhPCXOTGiGoWi0Olac26oIjvk8lRb31r5IbwQqlung== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=telenet.be header.s=r22 header.b=I4xSLBin; dmarc=fail reason="SPF not aligned (relaxed)" header.from=telenet.be (policy=none); spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: -5.60 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=telenet.be header.s=r22 header.b=I4xSLBin; dmarc=fail reason="SPF not aligned (relaxed)" header.from=telenet.be (policy=none); spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: DD116F0ED X-Spam-Score: -5.60 X-Migadu-Scanner: scn0.migadu.com X-TUID: K2ifsc+9eLrl --=-K0kdrlY7wUTtQSQn9jfZ Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable zimoun schreef op di 04-01-2022 om 23:22 [+0100]: > 2) =E2=80=99auto=E2=80=99 is confusing=E2=80=A6 >=20 > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 (select? (negate vcs-fi= le?))) > > +=C2=A0 "Compute the hash of FILE with ALGORITHM.=C2=A0 If RECURSIVE? i= s #true or 'auto', > > +recurse into subdirectories of FILE, computing the combined hash (nar = hash) of >=20 > =E2=80=A6here I understand that =E2=80=99auto=E2=80=99 means #true=E2=80= =A6 Precisely, in the sense 'auto' means #true in that 'auto' recurses. But sometimes #true / auto compute a different hash ... > > +Keep in mind that the hash of a regular file depends on RECURSIVE?: > > +if the recursive hash is desired, it must be set to #true.=C2=A0 Other= wise, it must > > +be set to #false or 'auto'. In most situations, the non-recursive hash= is desired > > +for regular files." >=20 > =E2=80=A6but there it is the contrary. :-) No, when #:recursive? is 'auto' and the file is a directory, it recurses. When it is 'auto' and the file is a regular file, then it also recurses, albeit in a trivial way (because regular files don't contain other files). This comment explains that the 'recursive hash' (nar hash) and 'regular hash' of a regular file are different, that usually you want the regular hash for regular files, and implies that '#:recursive? auto' usually does the right thing. But if you really want the recursive hash for regular files, then you can still compute that by setting #:recursive? #true. > =C2=A0 To me, #true/#false or #t/#f are > meaningful, especially when=E2=80=A6 >=20 > > +=C2=A0 (if (or (eq? recursive? #true) > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 (and (eq? recur= sive? 'auto) >=20 > =E2=80=A6the symbol =E2=80=99auto=E2=80=99 is only used here.=C2=A0 IIRC = all the series. :-) In =E2=80=98[PATCH v4 3/4] refresh: Support non-tarball sources.=E2=80=99, = there's > + (let ((hash (file-hash* output))) There, #:recursive? is 'auto'. Greetings, Maxime --=-K0kdrlY7wUTtQSQn9jfZ Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part Content-Transfer-Encoding: 7bit -----BEGIN PGP SIGNATURE----- iI0EABYKADUWIQTB8z7iDFKP233XAR9J4+4iGRcl7gUCYdVtyhccbWF4aW1lZGV2 b3NAdGVsZW5ldC5iZQAKCRBJ4+4iGRcl7vd0AQC28roqlHxi5wsBXMukpA1Xlmp+ j8YOaunayI8shlCfbwEA2LdofI6Mqy06DFcjCFRONrh8BDgdD5wQ4yFSoU6qgg0= =sKUQ -----END PGP SIGNATURE----- --=-K0kdrlY7wUTtQSQn9jfZ--