All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Ævar Arnfjörð Bjarmason" <avarab@gmail.com>
To: git@vger.kernel.org
Cc: "Junio C Hamano" <gitster@pobox.com>, "Jeff King" <peff@peff.net>,
	"Taylor Blau" <me@ttaylorr.com>,
	"Robin H . Johnson" <robbat2@gentoo.org>,
	"Ævar Arnfjörð Bjarmason" <avarab@gmail.com>
Subject: [PATCH] bundle: remove ignored & undocumented "--verbose" flag
Date: Thu, 23 Sep 2021 18:48:22 +0200	[thread overview]
Message-ID: <patch-1.1-d61f4b28dfd-20210923T164636Z-avarab@gmail.com> (raw)

In 73c3253d75e (bundle: framework for options before bundle file,
2019-11-10) the "git bundle" command was refactored to use
parse_options(). In that refactoring it started understanding the
"--verbose" flag before the subcommand, e.g.:

    git bundle --verbose verify --quiet

However, nothing ever did anything with this "verbose" variable, and
the change wasn't documented. It appears to have been something that
escaped the lab, and wasn't flagged by reviewers at the time. Let's
just remove it.

Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
---

As a follow-up to the discussion at
https://lore.kernel.org/git/87zgs593ja.fsf@evledraar.gmail.com/ I
looked at whether any other subcommands accepted "git cmd [opts]
subcommand", here's another special-case we can safely remove.

Perhaps this was from an earlier version of
https://lore.kernel.org/git/20191110204126.30553-1-robbat2@gentoo.org/,
but I could not find v1 and v2.

 builtin/bundle.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/builtin/bundle.c b/builtin/bundle.c
index 91975def2da..5a85d7cd0fe 100644
--- a/builtin/bundle.c
+++ b/builtin/bundle.c
@@ -39,8 +39,6 @@ static const char * const builtin_bundle_unbundle_usage[] = {
   NULL
 };
 
-static int verbose;
-
 static int parse_options_cmd_bundle(int argc,
 		const char **argv,
 		const char* prefix,
@@ -197,7 +195,6 @@ static int cmd_bundle_unbundle(int argc, const char **argv, const char *prefix)
 int cmd_bundle(int argc, const char **argv, const char *prefix)
 {
 	struct option options[] = {
-		OPT__VERBOSE(&verbose, N_("be verbose; must be placed before a subcommand")),
 		OPT_END()
 	};
 	int result;
-- 
2.33.0.1229.g7e7cef8c419


             reply	other threads:[~2021-09-23 16:48 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-23 16:48 Ævar Arnfjörð Bjarmason [this message]
2021-09-23 17:38 ` [PATCH] bundle: remove ignored & undocumented "--verbose" flag Taylor Blau

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=patch-1.1-d61f4b28dfd-20210923T164636Z-avarab@gmail.com \
    --to=avarab@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=me@ttaylorr.com \
    --cc=peff@peff.net \
    --cc=robbat2@gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.