🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: linux.kernel.git
Article #4211

Re: [PATCH 4/5] builtin/multi-pack-index: simplify how common options are wired up

#4211
From: Justin Tobler
Date: Tue, 01 Dec 2026 17:13
31 lines
11893 bytes
On 26/12/01 11:58AM, Patrick Steinhardt wrote:
> On Mon, Nov 30, 2026 at 03:55:00PM -0600, Justin Tobler wrote:
> > @@ -154,8 +147,7 @@ static int cmd_multi_pack_index_write(int argc, const char **argv,
> >  				      const char *prefix,
> >  				      struct repository *repo)
> >  {
> > -	struct option *options;
> > -	static struct option builtin_multi_pack_index_write_options[] = {
> > +	static struct option options[] = {
> >  		OPT_STRING(0, "preferred-pack", &opts.preferred_pack,
> >  			   N_("preferred-pack"),
> >  			   N_("pack for reuse when computing a multi-pack bitmap")),
> > @@ -172,6 +164,7 @@ static int cmd_multi_pack_index_write(int argc, const char **argv,
> >  			 N_("write multi-pack index containing only given indexes")),
> >  		OPT_FILENAME(0, "refs-snapshot", &opts.refs_snapshot,
> >  			     N_("refs snapshot for selecting bitmap commits")),
> > +		MULTI_PACK_INDEX_COMMON_OPTIONS(&opts),
> >  		OPT_END(),
> >  	};
> >  	struct odb_source_packed *packed_source;
> 
> I think this causes a slight change in that the common opitons are now
> at the end of these options, whereas they have been at the beginning
> beforehand. Doesn't really matter much, but it can also easily be
> avoided by adding the common options first.

Good catch. I'll move the common options to the front in the next
version.

-Justin
Technical Details
Message-ID: <aw7_6efAzLClbLMY@denethor>
Path: mbox-mo1.pugleaf.net!srv.newsdeef.eu!news.mb-net.net!open-news-network.org!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!git+bounces-76807-linux-kernel-git=dewy.ru
References: <cover.1796075503.git.jltobler@gmail.com> <1c16a0988239253b3695c68c138b4b71ccc00de9.1796075503.git.jltobler@gmail.com> <aw6oWC_yENDJjd3h@pks.im>

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!srv.newsdeef.eu!news.mb-net.net!open-news-network.org!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!git+bounces-76807-linux-kernel-git=dewy.ru
From: jltobler@gmail.com (Justin Tobler)
Newsgroups: linux.kernel.git
Subject: Re: [PATCH 4/5] builtin/multi-pack-index: simplify how common
 options are wired up
Date: Tue, 1 Dec 2026 11:13:00 -0600
Organization: Usenet Network
Message-ID: <aw7_6efAzLClbLMY@denethor>
References: <cover.1796075503.git.jltobler@gmail.com>
 <1c16a0988239253b3695c68c138b4b71ccc00de9.1796075503.git.jltobler@gmail.com>
 <aw6oWC_yENDJjd3h@pks.im>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Injection-Info: usenet.network;
	logging-data="1774778"; mail-complaints-to="abuse@usenet.network"
Cancel-Lock: sha1:LS9jxnAyacXk9dR/+qaXgbcr/Cc= sha256:ClJrfAwgr1DiE7HqqtpXC4AO8W5iiXyVHQw3QVrPn38=
	sha1:jdZnEKa5qA1AdcJWzanIIcvhf/8= sha256:5zkLwVvSf9En6GXk4sDaeqyHLuXYMAVffUGohfbMVaQ=
Content-Disposition: inline
List-ID: <git.vger.kernel.org>
X-Mailpost-Empty-Hdrs: X-Spam-Level
X-Received: from localhost (localhost [127.0.0.1])
	by mail.dewy.ru (Postfix) with ESMTP id 2C6D8117429; Tue,  1 Dec 2026 20:13:18 +0300 (MSK)
X-Virus-Scanned: Debian amavisd-new at usenet.network
X-Spam-Flag: NO
X-Spam-Score: -1.949
X-Spam-Status: No, score=-1.949 tagged_above=-9999 required=6.31
	tests=[DCC_CHECK=1.1, DCC_REPUT_70_89=0.1, DKIM_SIGNED=0.1,
	DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.001,
	FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.249,
	MAILING_LIST_MULTI=-1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001,
	SPF_PASS=-0.001] autolearn=ham autolearn_force=no
X-Authentication-Results: mail.dewy.ru (amavisd-new); dkim=pass (2048-bit key)
	header.d=gmail.com
X-Received: from mail.dewy.ru ([127.0.0.1])
	by localhost (mail.dewy.ru [127.0.0.1]) (amavisd-new, port 10024)
	with ESMTP id vy6Dvf1uKCJp;
	Tue,  1 Dec 2026 20:13:14 +0300 (MSK)
X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.234.253.10; helo=sea.lore.kernel.org; envelope-from=git+bounces-76807-linux-kernel-git=dewy.ru@vger.kernel.org; receiver=<UNKNOWN> 
X-Authentication-Results: OpenDMARC; dmarc=fail (p=none dis=none) header.from=gmail.com
X-Received: from sea.lore.kernel.org (sea.lore.kernel.org [172.234.253.10])
	by mail.dewy.ru (Postfix) with ESMTPS id 704B3117424; Tue,  1 Dec 2026 20:13:06 +0300 (MSK)
X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92])
	by sea.lore.kernel.org (Postfix) with ESMTP id BFE622D507; Tue,  1 Dec 2026 17:13:04 +0000 (UTC)
X-Authentication-Results: smtp.subspace.kernel.org; arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1
X-ARC-Seal: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=pass;
	t=1796145184;
	b=gP0IU1gaRzIBf10ir6qCc2qTi7TfMNhPvhGJfa3enKR89jVsevpY4n+7X0RPBMFqHy6Q
	 IjHEgCZNqv9DREqbZszSRVrYFppNugNzqeTF19HADyNkYo+lz/vnWSZJpfSWheJmk49pB
	 yfAWdwxTZ0B6RU5VCKM7I3QtflTPY2CUPJZY1o/gXLkBPNJKLGcpii1XfSpanOSqgMP7D
	 H1XqkPEJkjtHlInPdAS7LrPtTA60D+cS2Rwz/9XNykARUN+57k7nMFVF2iUCJVRu2fVIC
	 Fhlcg2xAiIf2oZRXkBPoaXCRywWLN9p3RxKjROt8xUGqTKi46lFjlZy3sqS184T1WJw==
X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015;
	a=rsa-sha256; c=relaxed/relaxed; t=1796145184;
	h=X-Original-To:Received:DMARC-Filter:Received:DKIM-Signature:
	 X-Google-DKIM-Signature:X-Gm-Message-State:X-Gm-Gg:X-Received:
	 Received:Date:From:To:Cc:Subject:Message-ID:References:X-Mailing-List:
	 List-Id:List-Post:List-Help:List-Subscribe:List-Unsubscribe:
	 List-Owner:Precedence:MIME-Version:Content-Type:Content-Disposition:
	 In-Reply-To;
	bh=F8Jl9NJfDwUUHcUPHKtTtlqooVDX4S071d32wuBs7xc=;
	b=Fvip6OxetpuNVvOBfqnmiu34MCI0E2khG2oGunHdOrPHD+h5v3iLubeIb9Kch/EQSfLP
	 eGilQIWgNWO448BbqFvkYRZP23ZM9XKuVOo7gChKyJXbCVysaXWAy6mP6metjryd9ZfGA
	 575Z6EnowFbtG/iybjR0Hal06SwTLokNXa+i+tCu6dACUtvNtH0+W49WxIBYkx/WS+dlt
	 4pgA0+oB1Wa5hxdUlbB6acbXmOdfKcp+jHHke4Z5Mf023gcEzu0dedMuSzXSkfG5+Fw9f
	 CLYhU5I4izYdi+sdvzss9pNfIDH+oQzn+onglTY64WHRKDLhRKvrRG4sIc3KPx5XARw==
X-ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; 
	dkim=pass header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20260707 header.b=hkiuBFmo;
	dmarc=pass header.from=gmail.com;
	spf=pass smtp.mailfrom=gmail.com;
	arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1
X-Received: from localhost.localdomain (localhost [127.0.0.1])
	by smtp.subspace.kernel.org (Postfix) with ESMTP id 96243606A32A;
	Tue,  1 Dec 2026 17:13:04 +0000 (UTC)
X-Authentication-Results: smtp.subspace.kernel.org;
	dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20260707 header.b=hkiuBFmo
X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=209.85.160.52
X-ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none;
	t=1796145183;
	b=Sop5EmOLPK11Kv/xKUnaWNqHwoA3Y0LA67hqLgqIOvH3PMEohWuMMGR2BwZW2Rwm7RXt
	 40nVVTIxqC6Ljz48lgJt6bX67uVSSmeQ0cWeHigLoMifM/ukw8t4Vnt7VkORuJLm7nzYE
	 rVE82dTjTIm4Vb81HnBKp4yrj0TcuaW1/tsqs9MeIwKbnmQum5BqoTu5YDjt3rqplkDJj
	 ThSdt/W6kL02Pe2zmj/RvrKLk1R5JOxSx99t4+vxwLv4OcT4fgEQlevsbvkAVn+cpOViX
	 KxASedJXhO7ltOpq/BJIJfaTeG6bmBj9xdRhEXhwC7z6hd1g3JEFECPNcQC3bXbHpNw==
X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015;
	a=rsa-sha256; c=relaxed/relaxed; t=1796145183;
	h=DMARC-Filter:Received:DKIM-Signature:X-Google-DKIM-Signature:
	 X-Gm-Message-State:X-Gm-Gg:X-Received:Received:Date:From:To:Cc:
	 Subject:Message-ID:References:MIME-Version:Content-Type:
	 Content-Disposition:In-Reply-To;
	bh=F8Jl9NJfDwUUHcUPHKtTtlqooVDX4S071d32wuBs7xc=;
	b=MAtxMPvB5FmVsZb7X7yOBIFtSWpIbK+M6f5t7JHM8QvQ+RyIPcB5S/733Z+SjVbw/51v
	 jwLP5+0MciQpa+HB4nTuWtQhd9JyZi8AQ7quMpLnAIQv50u0aV/QlpO1h0B1DdNlC0Fu+
	 tXeCzLbF12ZOSh39Fu+zW5toMqNe/qib/kzUYwxY+LPzrAoxhT3KtGeFgTIGzSBHqfRhy
	 7N4iHEn5mqFY8cULHRlAkEGLBzWD30OGLTY3RKK9Pxt/6HFWWQOFiXqyVzNsusu3hVJrY
	 dg2sqzQZT6H2k5QLcNU4WNFb/Inaj/SmgARyrVuLmKSsjYraBCAHsGGAjrH0CLWih5A==
X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; 
	dmarc=pass header.from=gmail.com;
	spf=pass smtp.mailfrom=gmail.com;
	dkim=pass header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20260707 header.b=hkiuBFmo;
	arc=none smtp.remote-ip=209.85.160.52
X-Received: from mail-oa1-f52.google.com (mail-oa1-f52.google.com [209.85.160.52])
	(using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)
	 key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256)
	(No client certificate requested)
	by smtp.subspace.kernel.org (Postfix) with ESMTPS id 60DAB606A320
	for <git@vger.kernel.org>; Tue,  1 Dec 2026 17:13:03 +0000 (UTC)
X-DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 60DAB606A320
X-Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com
X-Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com
X-Received: by mail-oa1-f52.google.com with SMTP id 586e51a60fabf-48e9476e26aso4249727fac.3
        for <git@vger.kernel.org>; Tue, 01 Dec 2026 09:13:03 -0800 (PST)
X-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=gmail.com; s=20260707; t=1796145182; x=1796749982; darn=vger.kernel.org;
        h=in-reply-to:content-disposition:content-type:mime-version
         :references:message-id:subject:cc:to:from:date:from:to:cc:subject
         :date:message-id:reply-to:content-type;
        bh=F8Jl9NJfDwUUHcUPHKtTtlqooVDX4S071d32wuBs7xc=;
        b=hkiuBFmo3RDEBMJYySoZJcezQSI15jsrjQjrH7PSdzzr8pCSPncRJHEtqN1i988R97
         0E8bbQLzO8RoN3P1kFCN2mFASxqrGRQuZocVVAIqN6o+fzlMEvQ0Myl6zshcSU2XZgz9
         Q59Ln4cet44/abWLwMQr+9XAR2pGAvltUQXEHD6zHh5DriN0ntoA9xWQPggI2nPf7djq
         ui5ZzMoXxjeN++g7JGr4dVICs+Me1mWn66maMtF2ScfrKRpfT84lGzq3lYz3PtT+07sz
         2nKGIuGRoi60vjkmnKr2KX/A3jSPLTV+McTDG0Pibp4yowYRgqNc8oR8kc+XmLmHvxTh
         mlrg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=1e100.net; s=20260707; t=1796145182; x=1796749982;
        h=in-reply-to:content-disposition:content-type:mime-version
         :references:message-id:subject:cc:to:from:date:x-gm-gg
         :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to
         :content-type;
        bh=F8Jl9NJfDwUUHcUPHKtTtlqooVDX4S071d32wuBs7xc=;
        b=gh9kPC4W4iUpEWG/A5/6GMjRgnjAqmaZVyM90SwL8N1g/IfSBQ7T4FTptjMXnlZ/J/
         zJIxbZNqYqrqMXSxVAzS2ifKyrxQDvnCS7U5GG/mgb/kATo0ABhgWVjYgL/LkR+eVjgp
         2c+oT+Z82aqIoitPlbAtSQtSuDThtysk9/riofD0nr+gRmCk2947HIjEMvymL531cCg2
         GHSmEWbMgRespQ6VIwssYcJX0hMRDSW8Zx++xUQIIwI0yfOMmwpitiZjhr5I7EPldNRd
         r/5V0T5+MRkH31iIWXCTSf8Gl+s4gMT0sPTuC6Jb6NCCUrentVgt2na2rsv26E/Rmbrg
         tlNg==
X-Gm-Message-State: APuU4Z97yquN5Z1GJDxueOqHte0By3Qi8y/LhRUssqcYd8u2GiI79Scp
	pS3OfdMkKVlzftpodDGa57/LYL5OOneZu2az+NtWHC756R6J0LVU0ag13+V1Nw==
X-Gm-Gg: AZFdTZfzKF9yZUwtC5pRw8KOPTUz3df2hqXP9bJZpljbA0/IabEBdF/yPkVSoKUiv9f
	AI2g3etzndEga7bHkCKhQngkHJhrqCKZkTJOEqRYsy1EoK3uEtrcYQsBc9ow1N5KWxQ/3ahNbnW
	UXsORg/9460vZI1wZK5+s2dR0jb2z8H7M4Emwn9QLIcmsfg04R+1wlkauP2LSLACvWeR+6LG/mg
	CR0EtqxpVkaIliCmaxpKGeJWp67ai4Qi0bBhwmKsKk1rlmei/YT4n6SqzUkJVYAs+gLXdxt9mhx
	4UEqgMG4vu7p78G68wl4aLQlNfeOMyH3H1VCjbRCgYOkrrPQ9jdP7CU8BObEQlZZ/MnZiW13F9C
	HshaM4suTdCa0Hx3iUpI0adnV60q/1jMl9O1MlGktLWDm0/Hpvv3uq+fUguG3xFeCju6MPlpBnM
	txvBUTGdvJQCDCd2hc6rt045SQJfjeLpzMnvW6qbUaNr+gzv5+QE8XXBaRlb+AUJj2hKoSg74mJ
	0udWEjHDzJX6zkgeW8nheNA1gkbVCtxuuR9f7Zh1LJePSOo8PTJs1XxmeQHwUmD4gm4kSmS7gea
	JWwHV0gGdCUFHfKAnLfrr2pOABlfWxd6IUvitOTt6FFcmPZFLP7c
X-Received: by 2002:a05:6871:7425:b0:4da:8fb9:1e75 with SMTP id 586e51a60fabf-4da8fd7a7abmr4476776fac.16.1796145182207;
        Tue, 01 Dec 2026 09:13:02 -0800 (PST)
X-Received: from localhost ([136.51.44.64])
        by smtp.gmail.com with ESMTPSA id 586e51a60fabf-4bc5f7ae7dcsm31110796fac.8.2026.12.01.09.13.01
        (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);
        Tue, 01 Dec 2026 09:13:01 -0800 (PST)
X-Cc: git@vger.kernel.org
X-Mailing-List: git@vger.kernel.org
X-List-Post: <mailto:git@vger.kernel.org>
X-List-Help: <mailto:git+help@vger.kernel.org>
X-List-Subscribe: <mailto:git+subscribe@vger.kernel.org>
X-List-Unsubscribe: <mailto:git+unsubscribe@vger.kernel.org>
X-List-Owner: <mailto:git+owner@vger.kernel.org>
X-Precedence: list
X-In-Reply-To: <aw6oWC_yENDJjd3h@pks.im>