From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.migadu.com ([2001:41d0:403:4789::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms8.migadu.com with LMTPS id yHTtKsFkNmXGIwAAG6o9tA:P1 (envelope-from ) for ; Mon, 23 Oct 2023 14:19:13 +0200 Received: from aspmx1.migadu.com ([2001:41d0:403:4789::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp10.migadu.com with LMTPS id yHTtKsFkNmXGIwAAG6o9tA (envelope-from ) for ; Mon, 23 Oct 2023 14:19:13 +0200 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 7909039019 for ; Mon, 23 Oct 2023 14:19:13 +0200 (CEST) Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20230601 header.b=JgYGP+gd; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of "bug-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="bug-guix-bounces+larch=yhetil.org@gnu.org" ARC-Seal: i=1; s=key1; d=yhetil.org; t=1698063553; a=rsa-sha256; cv=none; b=rCGX8dgijk9oJ3JN8/j77BVYU+b1k7UhjBQY9DL05suhpWnzY6NlCuA3/LHHTNsTfWBd4/ Wwq0XLX1YV+jcr5f0ih+eutRtcb8OjkK5avrppzhDY/JGT0dWnPNisLOgAYVOBE4F62Tyd tGMQaOWOefrUnmLw2XVcGTFaihm3U886hN2mZavYeQS0mn3HKLKdC3mZJ/7n6eXiOiQqsC cIKx1MH5uc5v8ohtC8hB2wfh7CqhSf0vWvVLw4arEyT10uoojaeoMEYRMAt2JQ+jzHXVZJ pSr3G8kCNN+WwXa875qLU+lLCTi4UiH9KP0XUR8ycenLESCumnLPSTHcvZPQYw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20230601 header.b=JgYGP+gd; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of "bug-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="bug-guix-bounces+larch=yhetil.org@gnu.org" ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1698063553; 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:dkim-signature; bh=Xt1z37opOQR08iqozxo1uMwugTW3bMHxKjeX7VAYwkI=; b=D8SNxL8PtIxqDtKb7Kc6Lew87TVolhsbnN5vMz+IM5eNBHb15ox3BpC9P6A1nkXR2WUEno B7EDol9Xx8r7BbkPjvgAEZJv60dHoEYo1MBWgJM4NXxuuhRq5YhWAJaY1FAwZTSvG38XhM R7mMI45Bn0v/hptrJXKCcAoQLEHIzxnjfH8wXUpJipp2AoLpNjdzHpeQ8L5s9UJIqpJxFT GzaphNX9O1NDoGe2VOttbHtP+cEqNlpGDxFOV1duhvhn+M2GiulMAGMdilL9obtH2VqA6a Ube2UEFEoNKpAgB/Ep+aEgSRNHNeNGCVIKJqyNG5IbC6m8oy35PgOUPU/oIf/Q== Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1quttH-0002Sj-0b; Mon, 23 Oct 2023 08:18:39 -0400 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 1quttD-0002PT-IF for bug-guix@gnu.org; Mon, 23 Oct 2023 08:18:35 -0400 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 1quttD-0005W3-9P for bug-guix@gnu.org; Mon, 23 Oct 2023 08:18:35 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1quttg-0006oZ-6n for bug-guix@gnu.org; Mon, 23 Oct 2023 08:19:04 -0400 X-Loop: help-debbugs@gnu.org Subject: bug#65720: [PATCH] git: Shell out to =?UTF-8?Q?=E2=80=98git_?= =?UTF-8?Q?gc=E2=80=99?= when necessary. Resent-From: Simon Tournier Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Mon, 23 Oct 2023 12:19:04 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65720 X-GNU-PR-Package: guix X-GNU-PR-Keywords: To: Ludovic =?UTF-8?Q?Court=C3=A8s?= , guix-patches@gnu.org Cc: Josselin Poiret , 65720@debbugs.gnu.org, Mathieu Othacehe , Ludovic =?UTF-8?Q?Court=C3=A8s?= , Tobias Geerinckx-Rice , Ricardo Wurmus , Christopher Baines Received: via spool by 65720-submit@debbugs.gnu.org id=B65720.169806350026071 (code B ref 65720); Mon, 23 Oct 2023 12:19:04 +0000 Received: (at 65720) by debbugs.gnu.org; 23 Oct 2023 12:18:20 +0000 Received: from localhost ([127.0.0.1]:49278 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qutsx-0006mL-PA for submit@debbugs.gnu.org; Mon, 23 Oct 2023 08:18:20 -0400 Received: from mail-wm1-x331.google.com ([2a00:1450:4864:20::331]:40255) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qutsq-0006l5-Oz for 65720@debbugs.gnu.org; Mon, 23 Oct 2023 08:18:13 -0400 Received: by mail-wm1-x331.google.com with SMTP id 5b1f17b1804b1-408cd9660b8so4432205e9.1 for <65720@debbugs.gnu.org>; Mon, 23 Oct 2023 05:17:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1698063458; x=1698668258; darn=debbugs.gnu.org; h=content-transfer-encoding:mime-version:message-id:date:references :in-reply-to:subject:cc:to:from:from:to:cc:subject:date:message-id :reply-to; bh=Xt1z37opOQR08iqozxo1uMwugTW3bMHxKjeX7VAYwkI=; b=JgYGP+gdIEjGyJ5VUIpBE7qMlQZ+lTB5ohsSJPymFk5HRirT8aNpkuV3AG4WpLYsZz kcUXe2g9tjoVW1NJ5H5DVR+yIs2xaJdu/8wBqtDiPxipRkHmY5ygvC1gJ1206ZjtGvba wyeeAGDbp0Ga2GNtBDIa4nrcE2HuLKJEbKwjG6EE8Ko+BSDoAC3yiCnRjQoMAjKoZ9MX 3xNHunhetb06wIGa5ChUz2aprHTRBx+a/6LqlJB0oWIwIxhnd3n4TdujLfYCkYLNvGrn jteoT2d6vztnN8SXdJCyz7j9ZvQ+V/n37hqwh8+1XGZBAaOaSPD1KQqZtW0DCuS8YYUH cflA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1698063458; x=1698668258; h=content-transfer-encoding:mime-version:message-id:date:references :in-reply-to:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=Xt1z37opOQR08iqozxo1uMwugTW3bMHxKjeX7VAYwkI=; b=TPweRg+9jT5Z5zxVb59R2L8uj+B+QUd+G0KoftaIXN71rwGL7NS6PU2K6gvzlNTTDU dFth5jJrkNCUJdxz7DzdAGLczNUJO6Dnnx7WMD5dCKxzP68R3SfMBw4Eehk/P3ZT1s0p +5V7uxhIqus/hSZkW6eTjVmSKjM3tZzohm4oVVKGqrj1YKQ1H0EhSGZphzmNqHTYpWqR hHxdI0DwQKbd5BdQJEQR4DF+a6giPWjzXBsXbNyehQP1qb2r+CjcDsvW77MHI1YumIGY olBQ2R7feyqCHrJvbHooI0hoigZycXJlwNNd8aQxa5fuA5ldkLYwQfqvkDvnYXHAPAdr Txdw== X-Gm-Message-State: AOJu0YywLb80j5Mo+WJ4QMcz9MTqDWkNQ8oSsMuccToZrrnbc8nAC27m cId2ol8SbtQSpK7saVx2Doz8LGYImls= X-Google-Smtp-Source: AGHT+IEUzcGeauVNAvtPZyCJG5W/D/IQc51htixeCW/va1rc4v1+V80hfJuzOx11Em45vywMXPcnmA== X-Received: by 2002:a05:600c:3b23:b0:401:c07f:72bd with SMTP id m35-20020a05600c3b2300b00401c07f72bdmr6846951wms.4.1698063457671; Mon, 23 Oct 2023 05:17:37 -0700 (PDT) Received: from pfiuh07 ([193.48.40.241]) by smtp.gmail.com with ESMTPSA id g17-20020a5d5551000000b0032cc35c2ef7sm7674108wrw.29.2023.10.23.05.17.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 23 Oct 2023 05:17:37 -0700 (PDT) From: Simon Tournier In-Reply-To: References: <87jzswsrlt.fsf@gnu.org> Date: Mon, 23 Oct 2023 12:08:07 +0200 Message-ID: <87il6xlkhk.fsf@gmail.com> 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: bug-guix@gnu.org List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guix-bounces+larch=yhetil.org@gnu.org Sender: bug-guix-bounces+larch=yhetil.org@gnu.org X-Migadu-Country: US X-Migadu-Flow: FLOW_IN X-Migadu-Scanner: mx1.migadu.com X-Migadu-Spam-Score: 2.87 X-Spam-Score: 2.87 X-Migadu-Queue-Id: 7909039019 X-TUID: rTQ2Xxvm4bjN Hi Ludo, On Fri, 20 Oct 2023 at 18:15, Ludovic Court=C3=A8s wrote: > * guix/git.scm (packs-in-git-repository, maybe-run-git-gc): New > procedures. > (update-cached-checkout): Use it. > --- > guix/git.scm | 39 ++++++++++++++++++++++++++++++++++++--- > 1 file changed, 36 insertions(+), 3 deletions(-) LGTM. Just two colors for the bikeshed. :-) > + (when (> (packs-in-git-repository directory) 25) Why 25? And not 10 or 50 or 100? > (define* (update-cached-checkout url > #:key > (ref '()) > @@ -515,6 +545,9 @@ (define* (update-cached-checkout url > seconds seconds > nanoseconds nanoseconds)))) >=20=20 > + ;; Run 'git gc' if needed. > + (maybe-run-git-gc cache-directory) Why not trigger it by =E2=80=9Cguix gc=E2=80=9D? Well, I expect =E2=80=9Cguix gc=E2=80=9D to take some time and I choose whe= n. However, I want =E2=80=9Cguix pull=E2=80=9D or =E2=80=9Cguix time-machine=E2=80=9D t= o be as fast as possible and here some extra time is added, and I cannot control exactly when. Cheers, simon