From: Junio C Hamano Date: Wed, 15 Apr 2026 21:57:15 GMT Subject: Re: [PATCH v2 2/7] fetch: add --negotiation-restrict option Message-ID: In-Reply-To: <9a25b0fadebb5f0219ceeca9496fc6f84abd020c.1776266066.git.gitgitgadget@gmail.com> "Derrick Stolee via GitGitGadget" writes: > - warning("ignoring --negotiation-tip=%s because it does not match any refs", > - s); > + warning(_("ignoring %s=%s because it does not match any refs"), > + "--negotiation-restrict", s); > - warning("ignoring --negotiation-tip because the protocol does not support it"); > + warning(_("ignoring %s because the protocol does not support it"), > + "--negotiation-restrict"); These are nice touches to make sure translators cannot possibly botch these option names that must be given verbatim. > } > return transport; > } > @@ -2567,6 +2568,8 @@ int cmd_fetch(int argc, > OPT_IPVERSION(&family), > OPT_STRING_LIST(0, "negotiation-tip", &negotiation_tip, N_("revision"), > N_("report that we have only objects reachable from this object")), > + OPT_STRING_LIST(0, "negotiation-restrict", &negotiation_tip, N_("revision"), > + N_("report that we have only objects reachable from this object")), Is OPT_ALIAS() suitable for this? > @@ -2657,7 +2660,7 @@ int cmd_fetch(int argc, > } > > if (negotiate_only && !negotiation_tip.nr) > - die(_("--negotiate-only needs one or more --negotiation-tip=*")); > + die(_("--negotiate-only needs one or more --negotiation-restrict=*")); OK. Shouldn't this also do the "%s" thing?