From: "Björn Steinbrink" <B.Steinbrink@gmx.de>
To: Paolo Bonzini <bonzini@gnu.org>
Cc: git@vger.kernel.org, gitster@pobox.com
Subject: Re: [PATCH 2/3] push: add --current
Date: Mon, 20 Jul 2009 09:14:13 +0200 [thread overview]
Message-ID: <20090720071413.GA29915@atjola.homenet> (raw)
In-Reply-To: <1248071820-18289-3-git-send-email-bonzini@gnu.org>
On 2009.07.20 08:36:59 +0200, Paolo Bonzini wrote:
> +--current::
> + Independent of the other options, restrict pushing to the current
> + HEAD.
To me, this sounds like there are multiple HEADs and this selects the
current one to be pushed, which would be wrong. Maybe this could be
written as:
Restrict pushing to the currently checked out branch head.
Which is also in line with the error message that is produced when
you're on a detached HEAD.
> +Refspecs given in the configuration are still used to find the
> +destination name of the current branch. However, this option cannot
> +be specified if an explicit refspec is given on the command line,
> +because it would be useless and possibly confusing.
Hm, this only talks about refspecs in the config, but your patch series
is especially about push.default=tracking, which is not a refspec set in
the config, but causes a refspec to be generated on the fly. Maybe:
With this option, defaults given in the configuration, either as
push refspecs for the remote or as a global push default, are
still evaluated, but only the currently checked out branch is
pushed. This means that this option, unlike the `HEAD` refspec,
supports a destination name that differs from the source name.
However, this option cannot be specified if an explicit refspec
is given on the command line, because it would be useless and
possibly confusing.
Which also explains a bit how this option differs from using the HEAD
refspec.
> ++
> +Additionally, if there is no refspec in the configuration and no
> +`push.default` configuration either, with this option git will use a
> +default refspec of `HEAD` rather than `:`.
Hm, this looks kind of funny with my rewrite of the previous paragraph,
so:
Additionally, if there are no push defaults given in the
configuration at all, this option makes git default to `HEAD`
instead of `:`.
Björn
next prev parent reply other threads:[~2009-07-20 7:14 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-07-20 6:36 [PATCH 0/3] add push --current and remote.*.pushHeadOnly Paolo Bonzini
2009-07-20 6:36 ` [PATCH 1/3] reintroduce PUSH_DEFAULT_UNSPECIFIED Paolo Bonzini
2009-07-20 6:36 ` [PATCH 2/3] push: add --current Paolo Bonzini
2009-07-20 7:14 ` Björn Steinbrink [this message]
2009-07-20 9:48 ` Paolo Bonzini
2009-07-20 10:15 ` Tay Ray Chuan
2009-07-20 11:50 ` Paolo Bonzini
2009-07-20 11:17 ` demerphq
2009-07-20 6:37 ` [PATCH 3/3] push: add remote.*.pushHeadOnly configuration Paolo Bonzini
-- strict thread matches above, loose matches on Subject: below --
2009-07-20 11:58 [PATCH v3 0/3] add push --current and remote.*.pushHeadOnly Paolo Bonzini
2009-07-20 11:58 ` [PATCH 2/3] push: add --current Paolo Bonzini
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=20090720071413.GA29915@atjola.homenet \
--to=b.steinbrink@gmx.de \
--cc=bonzini@gnu.org \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
/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 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 NNTP newsgroup(s).