mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Teng Long <>
Subject: Re: [RFC PATCH 0/1] push: introduce '--heads' option
Date: Thu, 15 Dec 2022 20:27:19 +0800	[thread overview]
Message-ID: <> (raw)
In-Reply-To: <xmqqilippgp2.fsf@gitster.g>

Junio C Hamano <> writes:

> My knee-jerk reaction is to avoid "--heads" and instead use
> "--branches", if this is about pushing all local branches.  The
> option "--heads" may still remain in some commands added to the
> system in the earliest part of our history, but soon we started
> to use "branch" over "head", as it is a more commonly used word.

OK, that's true, I just misled by some existing '--heads' in other

> How should it interact with --follow-tags?  Just as if you listed
> all local branch names on the command line?  I.e. is

Actually I didn't try '--follow-tags' before, but the documentation
about it is a  ittle hard to understand for me on first reading. Then,
I think it supports to use as negative '--[no-]follow-tags' but not
marked in the git-push.txt documentation.

>     git push $URL --heads
> equivalent to the long-hand
>     git push $URL $(git for-each-ref --format='%(refname)' refs/heads/\*)

git push $URL $(git for-each-ref --format='%(refname)' refs/heads/\*\*) maybe
to recursivly subdirectories matching?

Actually I didn't get why you represent this, maybe try to let's us know there
is another way we could make it as the same result?

> and because of that, does
>     git push $URL --any --other --option --heads
> behave identically to the long-hand with these other options added?

I think you concerned about the compatibility with the interaction of
the options, if so, I think a direct way is to keep --all and --heads
both have the some behavior when interact with other options, a little
confused why we have to use the long-hand to do that.

By the way, it seems like there are no specify tests for '--all', maybe
we can add some tests about '--all' first if this RFC patch is worthy to


  reply	other threads:[~2022-12-15 12:27 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-05 13:35 [RFC PATCH 0/1] push: introduce '--heads' option Teng Long
2022-12-05 13:35 ` [RFC PATCH 1/1] " Teng Long
2022-12-05 14:23   ` ZheNing Hu
2022-12-06 12:18     ` Teng Long
2023-04-28 12:21   ` Felipe Contreras
2023-04-30  1:05     ` Teng Long
2023-05-06 11:27   ` [PATCH 0/1] push: introduce '--branches' option Teng Long
2023-05-06 11:27     ` [PATCH 1/1] " Teng Long
2023-05-06 11:36     ` [PATCH 0/1] " Teng Long
2022-12-05 23:35 ` [RFC PATCH 0/1] push: introduce '--heads' option Junio C Hamano
2022-12-15 12:27   ` Teng Long [this message]
2023-04-28  9:59   ` Teng Long
2023-04-28 18:48     ` Junio C Hamano
2023-04-30  1:09       ` Teng Long
2023-05-06 11:34 ` [PATCH 0/1] push: introduce '--branches' option Teng Long
2023-05-06 11:34   ` [PATCH 1/1] " Teng Long
2023-05-06 21:39     ` Junio C Hamano
2023-05-07  6:43       ` Teng Long

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:

  List information:

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

  git send-email \ \ \ \ \ \ \ \

* 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.
Code repositories for project(s) associated with this public inbox

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).