From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms13.migadu.com with LMTPS id wLY7DJG8SWeY1wAAe85BDQ:P1 (envelope-from ) for ; Fri, 29 Nov 2024 13:07:29 +0000 Received: from aspmx1.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2.migadu.com with LMTPS id wLY7DJG8SWeY1wAAe85BDQ (envelope-from ) for ; Fri, 29 Nov 2024 14:07:29 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=debbugs.gnu.org header.s=debbugs-gnu-org header.b=kvwwqPOx; dkim=fail ("headers rsa verify failed") header.d=gnu.org header.s=fencepost-gnu-org header.b=pB1b+m1M; 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"; dmarc=pass (policy=none) header.from=gnu.org 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 4EE6246FEC for ; Fri, 29 Nov 2024 14:07:23 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tH0i8-0000zy-8B; Fri, 29 Nov 2024 08:07:04 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tH0i6-0000zl-OD for guix-patches@gnu.org; Fri, 29 Nov 2024 08:07:02 -0500 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tH0i6-00010O-Em for guix-patches@gnu.org; Fri, 29 Nov 2024 08:07:02 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:Date:References:In-Reply-To:From:To:Subject; bh=/p0VM10gaylN2b4PiDpVPokJoUCycT0oWpGcZbtn4nE=; b=kvwwqPOxUJcA7ix2PWkodoWsWIm/KdtpcbQce0+8VywFvpL7gnd2YPuLyobbptLfNJ9teGPJs6zzkRaN41iVh460FzgukhHKz8Z3p+81Dx0EuMhNvXry+wBEfJdAoWUlBKV1ZHL/ri2xNOOndAua12CsriM3u60VkcyTzgZbVAyn2Xuht867SZeJqVhx5BAHMXkVDXzw8PrqlrqlexS7YNtsB/xwYBFGO6uKB/B1QoxMJAYpS6uxc6oebdVYIjXxHNcv2ZMc04XkSIskzjoYKxfU8ZxtGUCqG7Yl9eEuJj/0W9dAsc3F9cVK8Xs8DCV+QWs2kXksZk45pnDfLioCug==; Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1tH0i5-0007Sh-Us for guix-patches@gnu.org; Fri, 29 Nov 2024 08:07:01 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#73833] [PATCH v2 1/5] guix: import: utils: Add function git->origin. Resent-From: Ludovic =?UTF-8?Q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 29 Nov 2024 13:07:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 73833 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Nicolas Graves Cc: 73833@debbugs.gnu.org Received: via spool by 73833-submit@debbugs.gnu.org id=B73833.173288556928606 (code B ref 73833); Fri, 29 Nov 2024 13:07:01 +0000 Received: (at 73833) by debbugs.gnu.org; 29 Nov 2024 13:06:09 +0000 Received: from localhost ([127.0.0.1]:41448 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tH0hF-0007RK-FD for submit@debbugs.gnu.org; Fri, 29 Nov 2024 08:06:09 -0500 Received: from eggs.gnu.org ([209.51.188.92]:35596) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tH0hD-0007R5-2D for 73833@debbugs.gnu.org; Fri, 29 Nov 2024 08:06:08 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tH0h1-0000YI-QR; Fri, 29 Nov 2024 08:05:57 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:Date:References:In-Reply-To:Subject:To: From; bh=/p0VM10gaylN2b4PiDpVPokJoUCycT0oWpGcZbtn4nE=; b=pB1b+m1MNH1AG3mGHc5B HtdjENXjsTiwvZkFk4ilG39bIAB+QM0XlrFIiBydu9dbw+NCi2gQcgNzxOc77SzTDd3wFgphSjOrw X5sKal4yl7M8qFLRN2LrdSIS8gEj+Zc+1nYgTuTFYPqeMn2CKRu6w7npjq5+bnGK1fqITDTofmzbb M2V7Uw7Ov/t1mgtFDz1EPyviR2zi5Rvc+GR4tI4gK7Gr8T5z47n9LylBknjbLRVr35LHtYlgNlkbp gVE/Nx4lgBuZv9GNifkLRRq1ChS/ShHZ+ajBp9wOpslAt2WKG3UhHOArD8mn0B9U+mx041glaOOeC 60dZdssA/5Wfew==; From: Ludovic =?UTF-8?Q?Court=C3=A8s?= In-Reply-To: <87ttck9t7r.fsf@ngraves.fr> (Nicolas Graves's message of "Wed, 06 Nov 2024 18:18:16 +0100") References: <20241017223308.27941-1-ngraves@ngraves.fr> <20241017223308.27941-2-ngraves@ngraves.fr> <87zfmcwfy5.fsf@gnu.org> <87ttck9t7r.fsf@ngraves.fr> Date: Fri, 29 Nov 2024 14:05:52 +0100 Message-ID: <87a5di2nrj.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) 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-bounces+larch=yhetil.org@gnu.org X-Migadu-Country: US X-Migadu-Flow: FLOW_IN X-Migadu-Scanner: mx11.migadu.com X-Migadu-Spam-Score: -3.54 X-Spam-Score: -3.54 X-Migadu-Queue-Id: 4EE6246FEC X-TUID: SOAnLJw1NCIb Hi, Nicolas Graves skribis: > On 2024-11-06 16:16, Ludovic Court=C3=A8s wrote: [...] >>> - ;; Use a custom cache to avoid cluttering the default one under >>> - ;; ~/.cache/guix, but choose one under /tmp so that it's persistent = across >>> - ;; subsequent "guix import" invocations. >>> - (mkdir-p cache) >>> - (chmod cache #o700) >>> - (let-values (((checkout commit _) >>> - (parameterize ((%repository-cache-directory cache)) >>> - (update-cached-checkout url >> >> Looks like this bit and its rationale in (guix import go) gets lost >> here: =E2=80=98git->origin=E2=80=99 unconditionally uses ~/.cache, which= means that >> =E2=80=98guix import go -r =E2=80=A6=E2=80=99 would fill that directory. >> >> Could we restore that behavior, probably as an option to >> =E2=80=98git->origin=E2=80=99? > > Yes, we can. However, IIRC my rationale was that the alternative used in > every other import module was to use the store (and not ~/.cache IIRC, > since it uses latest-repository-commit instead of > update-cached-checkout) as a cache. Since we often import/update to > build after that, it seemed quite natural to let the store handle the > cache instead of managing a custom cache for that. > > So yes, we loose a bit of functionality, but I think it's more > maintainable this way, if the original author doesn't disagree too much > on that. WDYT? =E2=80=98latest-repository-commit=E2=80=99 calls =E2=80=98update-cached-che= ckout=E2=80=99 to first get a copy of the repo under ~/.cache, and then import it into the store. So I think the functionality remains relevant. I=E2=80=99ve just used =E2=80=9Cguix import go -r code.forgejo.org/forgejo= =E2=80=9D and it ran out of disk space after filling /tmp with repos (!). The fact that it=E2= =80=99s in /tmp means I can easily remove it; otherwise I=E2=80=99d have to wipe al= l of ~/.cache/guix/checkouts, but that=E2=80=99d be inconvenient (my next pull/time-machine would have to re-clone the Guix repo, for instance). Ludo=E2=80=99.