From: Jeff King <peff@peff.net>
To: Junio C Hamano <junkio@cox.net>
Cc: Nicolas Pitre <nico@cam.org>, git@vger.kernel.org
Subject: Re: confusion over the new branch and merge config
Date: Sat, 23 Dec 2006 00:12:11 -0500 [thread overview]
Message-ID: <20061223051210.GA29814@segfault.peff.net> (raw)
In-Reply-To: <7vd56cam66.fsf@assigned-by-dhcp.cox.net>
On Thu, Dec 21, 2006 at 03:01:21PM -0800, Junio C Hamano wrote:
> > $ git checkout -b local_next origin/next
>
> "git checkout -b next origin/next" should work just fine, I
> think.
>
> There was a talk about allowing "checkout -b <new> <track>" to
> add branch.<new>.merge and branch.<new>.remote if <track> can be
> proven to corresond uniquely to one remote and one branch from
> that remote; I think that would match the expectation most of
> the time but that "most" would not be 100% nor even 80%, so I
> think that should be an optional feature. In any case, there
> was a talk but there is no code yet.
BTW, is there some explanation why branch.*.merge specifies a _remote_
head? The following would make much more sense to me:
[branch "master"]
remote = origin
merge = refs/remotes/origin/master
Because I don't _care_ that the other guy calls it refs/heads/master. I
care that I'm pulling from refs/remotes/origin/master on my end (and
however I get stuff into that branch is defined by the remote).
It also means that even without a remote, the merge option makes sense
(e.g., if I do repeated merges from one local branch to another). And it
means that it's _always_ correct for "checkout -b <new> <track>" to set
branch.<new>.merge to <track>, without having to worry about finding an
appropriate remote.
-Peff
next prev parent reply other threads:[~2006-12-23 5:12 UTC|newest]
Thread overview: 45+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-12-21 22:17 confusion over the new branch and merge config Nicolas Pitre
2006-12-21 23:01 ` Junio C Hamano
2006-12-21 23:21 ` Sean
2006-12-22 0:39 ` Junio C Hamano
2006-12-22 0:46 ` Junio C Hamano
2006-12-22 1:01 ` Sean
2006-12-22 8:31 ` Andy Parkins
2006-12-22 7:50 ` Alan Chandler
2006-12-22 8:21 ` Junio C Hamano
2006-12-22 8:39 ` Andy Parkins
2006-12-22 15:25 ` Alan Chandler
2006-12-22 20:49 ` Nicolas Pitre
2006-12-22 21:04 ` Jakub Narebski
2006-12-22 21:20 ` Nicolas Pitre
2006-12-22 22:40 ` Jakub Narebski
2006-12-22 23:39 ` Junio C Hamano
2006-12-23 3:10 ` Tom Prince
2006-12-23 5:11 ` Nicolas Pitre
2006-12-23 5:12 ` Jeff King [this message]
2006-12-23 5:29 ` Nicolas Pitre
2006-12-23 6:15 ` Junio C Hamano
2006-12-23 6:22 ` Shawn Pearce
2006-12-23 6:28 ` Jeff King
2006-12-23 7:11 ` Junio C Hamano
2006-12-23 7:25 ` Jeff King
2006-12-23 9:51 ` Junio C Hamano
2006-12-23 10:40 ` Jakub Narebski
2006-12-23 15:58 ` Johannes Schindelin
2006-12-23 22:48 ` Jakub Narebski
2006-12-24 6:15 ` Jeff King
2006-12-24 20:49 ` Nicolas Pitre
2006-12-26 7:33 ` Jeff King
2007-01-02 14:49 ` Jeff King
2007-01-02 17:32 ` Junio C Hamano
2007-01-02 17:34 ` Jeff King
2007-01-02 20:04 ` Junio C Hamano
2007-01-02 20:30 ` Jakub Narebski
2007-01-03 0:24 ` Santi Béjar
2007-01-03 23:02 ` Jakub Narebski
2007-01-09 15:05 ` Jeff King
2007-01-09 16:18 ` Jeff King
2006-12-23 8:31 ` Jakub Narebski
2006-12-22 8:41 ` Andy Parkins
2006-12-22 9:39 ` Lars Hjemli
2006-12-22 15:10 ` Nicolas Pitre
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=20061223051210.GA29814@segfault.peff.net \
--to=peff@peff.net \
--cc=git@vger.kernel.org \
--cc=junkio@cox.net \
--cc=nico@cam.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 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).