Re: [PATCH] push.default: Rename 'tracking' to 'upstream'
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Feb 16, 2011, 18:37 UTC
- Message-ID
- <7vy65fkeqx.fsf@alter.siamese.dyndns.org>
- In-Reply-To
- <7v8vxflv7p.fsf@alter.siamese.dyndns.org>
Junio C Hamano <gitster@pobox.com> writes:
Show 5 quoted lines
> IOW, I consider --set-upstream that takes refs/remotes without bothering > to go through the remotes.<name>.fetch mapping is a design bug (it may > have come from sloppy initial coding---it certainly is easier to store > what you get without computing anything). That may be something we might > want to fix in 1.8.0.
Please scratch this paragraph; this was a sloppy thinking on my part. The option, and its cousin --track, do call into setup_tracking() to look up the mapping.
The --set-upstream option needs to set both which remote's what branch, and refs/remotes/origin/master is a way to say "origin's master" and it was inevitable to expose refs/remotes/ to the UI level if you wanted to implement it as an option with a single argument. So in that sense there is nothing to fix.
Conceptually, "git branch --set-upstream=master --set-remote=origin" is what it really wants to say, even though that is probably longer to type. There still might be a room for UI improvement.