From: Jeff King <peff@peff.net>
To: Martin von Zweigbergk <martin.von.zweigbergk@gmail.com>
Cc: "Yann Dirson" <ydirson@free.fr>,
git@vger.kernel.org,
"Johannes Schindelin" <Johannes.Schindelin@gmx.de>,
"Santi Béjar" <santi@agolina.net>
Subject: Re: [RFC] rebase: use @{upstream} if no upstream specified
Date: Fri, 19 Nov 2010 23:10:12 -0500 [thread overview]
Message-ID: <20101120041011.GA20725@sigill.intra.peff.net> (raw)
In-Reply-To: <AANLkTikWYVyCf9mueoAHjGcQuNOdPFyQrmtW79As4RG-@mail.gmail.com>
On Fri, Nov 19, 2010 at 07:26:57PM -0500, Martin von Zweigbergk wrote:
> Yes, I did try that and I noticed that it worked, but it helps to know
> that it is not just by accident. I realize I was not very clear, but
> what I really was wondering if there is any advantage to using
> "git for-each-ref --format='%(upstream)' ${branch_name}" (as used by
> git pull) as compared to "git rev-parse @{upstream}" as suggested by
> Yann. ($branch_name in this case would be the current branch.)
No, I don't think there is a reason to prefer one over the other these
days. When the instance in git-parse-remote was written (e9460a6,
2009-06-12) @{upstream} did not yet exist (it came in 28fb843,
2009-09-10). So for-each-ref was the only way to get the informationa
I would use whichever one seems clearer in your context.
-Peff
next prev parent reply other threads:[~2010-11-20 4:10 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-11-12 20:55 [RFC] rebase: use @{upstream} if no upstream specified Martin von Zweigbergk
2010-11-13 9:51 ` Yann Dirson
2010-11-17 2:29 ` Martin von Zweigbergk
2010-11-19 21:15 ` Jeff King
2010-11-20 0:26 ` Martin von Zweigbergk
2010-11-20 4:10 ` Jeff King [this message]
2010-11-20 13:14 ` Martin von Zweigbergk
2010-11-15 22:48 ` Kevin Ballard
2010-11-15 23:06 ` Martin von Zweigbergk
2010-11-15 23:12 ` Jay Soffian
2010-11-15 23:16 ` Kevin Ballard
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=20101120041011.GA20725@sigill.intra.peff.net \
--to=peff@peff.net \
--cc=Johannes.Schindelin@gmx.de \
--cc=git@vger.kernel.org \
--cc=martin.von.zweigbergk@gmail.com \
--cc=santi@agolina.net \
--cc=ydirson@free.fr \
/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).