From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS54825 139.178.88.0/22 X-Spam-Status: No, score=-3.3 required=3.0 tests=AWL,BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE shortcircuit=no autolearn=ham autolearn_force=no version=3.4.6 Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org [139.178.88.99]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by dcvr.yhbt.net (Postfix) with ESMTPS id E825C1F44D for ; Tue, 20 Feb 2024 09:09:09 +0000 (UTC) Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id C74FF28E5CA for ; Tue, 20 Feb 2024 09:09:09 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id C1F7E604DD; Tue, 20 Feb 2024 09:06:54 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=pks.im header.i=@pks.im header.b="k4gJxb78"; dkim=pass (2048-bit key) header.d=messagingengine.com header.i=@messagingengine.com header.b="l9D0eYVW" Received: from wfout6-smtp.messagingengine.com (wfout6-smtp.messagingengine.com [64.147.123.149]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 83B855EE8B for ; Tue, 20 Feb 2024 09:06:51 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=64.147.123.149 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708420013; cv=none; b=VnrCEfP7hLdAg05vrNaBKcLz6f6+cz1arlsUw3WaAevLaT2eBAPa88FpFfudyazmTSAb1NavtHU1c2Ibzuio1WhisXBedH7SFn7hCDbsyBnjLEuFJe6jc3pp4L0DyTIMy2r0/3D3OEkBzB0LSjxA1mRWBuumlIUdCIgQ8/CUSIY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708420013; c=relaxed/simple; bh=f5qhfs8EYx8TvcQVPQI4SWHJkQ90FkKF9J8gCdpe8YM=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=Nea31zv7gaiqXF9Ns4oLnqvrOrVTJv1ny38lIvMkOejQSQ1HGNXeKJmYj57MPwOLKQGPmsZ7bY8ogBLQ817/58LOvKSokDKl6Hvugn/shLnpnSlftaFILNXErFLDcsJf9oUOX0XXQAxwIvvedEpee1tngjD3svMhfM1x0tOEVb4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=pks.im; spf=pass smtp.mailfrom=pks.im; dkim=pass (2048-bit key) header.d=pks.im header.i=@pks.im header.b=k4gJxb78; dkim=pass (2048-bit key) header.d=messagingengine.com header.i=@messagingengine.com header.b=l9D0eYVW; arc=none smtp.client-ip=64.147.123.149 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=pks.im Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=pks.im Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailfout.west.internal (Postfix) with ESMTP id 9BE671C00096; Tue, 20 Feb 2024 04:06:50 -0500 (EST) Received: from mailfrontend1 ([10.202.2.162]) by compute5.internal (MEProxy); Tue, 20 Feb 2024 04:06:50 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=pks.im; h=cc:cc :content-type:content-type:date:date:from:from:in-reply-to :in-reply-to:message-id:mime-version:references:reply-to:subject :subject:to:to; s=fm1; t=1708420010; x=1708506410; bh=J+pKgn089x Osq03zjCOKqO/bD+74mPT7v03KgMpJ6yM=; b=k4gJxb78zeSflzKIXS8A+aRQup Zh8ZtwYKbWF7pGeTBpb0fI9wWOyWSFkBJciwkvDfEf/UWPSx4K0tMx5LNIIafrBZ FMVAFegQ2eLw1COdy3haBWepCR+pgisCIewRjwtWevTrVz9kYB3Jkzvvi0rKL1Fs tputTYeKy0VsvoGfFdAWDeKqcHMShOXErT2jNtfZQcjIeLjnQ3eb9o7cuag6A0p4 QO0rCaY8i3DwxKuu/twWzXkx6JyMOOluDPCingucWsUA/HFkOKglmx9UaIu+jpS9 vHfADfqcB5TcMcczfYHDsY0QzKG5s3sfw+sQ37FT+pglbXfn7OZQ4OWzphwg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-type:content-type:date:date :feedback-id:feedback-id:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:subject:subject:to :to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s= fm1; t=1708420010; x=1708506410; bh=J+pKgn089xOsq03zjCOKqO/bD+74 mPT7v03KgMpJ6yM=; b=l9D0eYVWzwWFum/ZNZNIXlBMmAgqpnjmCrQ4HMVptDGq X51aqGcL43XZit9VDWbSthL5BWfqoEeSQB1SjkI6gLVtcoRIcOb62udMrushO9hP y+9l1AXscl1NGKpJgz1wGgeS4cdRoPylp0BMGd6RO3wRWSfGQZlrFri20pLnrBLY c0TujQNcRtsdFoQMxugU+6Clv6rJErkizLQr7Zz3prXP3/jmhAjUlBaqhiTMNwQO 1rYAC7jx7Ma42FOaB9E/9umSaVGrPQfIM7Z67TvTd/Cg5DAPjRB7dXKtYoXWuWzO 4W5hhkU9o2gNVBW4nDG5St6+k93Zjz55KJoaHPBg6A== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvledrfedtucetufdoteggodetrfdotffvucfrrh hofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgenuceurghi lhhouhhtmecufedttdenucenucfjughrpeffhffvvefukfhfgggtuggjsehgtderredttd dvnecuhfhrohhmpefrrghtrhhitghkucfuthgvihhnhhgrrhguthcuoehpshesphhkshdr ihhmqeenucggtffrrghtthgvrhhnpeeukedtvedtffevleejtefgheehieegkeeluddvfe efgeehgfeltddtheejleffteenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhep mhgrihhlfhhrohhmpehpshesphhkshdrihhm X-ME-Proxy: Feedback-ID: i197146af:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Tue, 20 Feb 2024 04:06:49 -0500 (EST) Received: by vm-mail (OpenSMTPD) with ESMTPSA id d0f04304 (TLSv1.3:TLS_AES_256_GCM_SHA384:256:NO); Tue, 20 Feb 2024 09:02:47 +0000 (UTC) Date: Tue, 20 Feb 2024 10:06:47 +0100 From: Patrick Steinhardt To: git@vger.kernel.org Cc: Junio C Hamano Subject: [PATCH v2 7/7] builtin/reflog: introduce subcommand to list reflogs Message-ID: References: Precedence: bulk X-Mailing-List: git@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="DGn8F9OaD0vZGign" Content-Disposition: inline In-Reply-To: --DGn8F9OaD0vZGign Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable While the git-reflog(1) command has subcommands to show reflog entries or check for reflog existence, it does not have any subcommands that would allow the user to enumerate all existing reflogs. This makes it quite hard to discover which reflogs a repository has. While this can be worked around with the "files" backend by enumerating files in the ".git/logs" directory, users of the "reftable" backend don't enjoy such a luxury. Introduce a new subcommand `git reflog list` that lists all reflogs the repository knows of to fill this gap. Signed-off-by: Patrick Steinhardt --- Documentation/git-reflog.txt | 3 ++ builtin/reflog.c | 34 ++++++++++++++++++ t/t1410-reflog.sh | 69 ++++++++++++++++++++++++++++++++++++ 3 files changed, 106 insertions(+) diff --git a/Documentation/git-reflog.txt b/Documentation/git-reflog.txt index ec64cbff4c..a929c52982 100644 --- a/Documentation/git-reflog.txt +++ b/Documentation/git-reflog.txt @@ -10,6 +10,7 @@ SYNOPSIS -------- [verse] 'git reflog' [show] [] [] +'git reflog list' 'git reflog expire' [--expire=3D