Re: [PATCH 1/3] branch: introduce --set-upstream-to
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Jul 10, 2012, 19:49 UTC
- Message-ID
- <7v1ukjiehe.fsf@alter.siamese.dyndns.org>
- In-Reply-To
- <20120710191354.GE8439@burratino>
Jonathan Nieder <jrnieder@gmail.com> writes:
Show 14 quoted lines
>> The existing --set-uptream option can cause confusion, as it uses the >> usual branch convention of assuming a starting point of HEAD if none >> is specified, causing >> >> git branch --set-upstream origin/master >> >> to create a new local branch 'origin/master' that tracks the current >> branch. As --set-upstream already exists, we can't simply change its >> behaviour. To work around this, introduce --set-upstream-to which >> accepts a compulsory argument > > Thanks. A part of me really dislikes this --set-upstream-to which > is named more awkwardly than the deprecated mistake it replaces, > though.
I am not super excited about it either, but at least it is a vast improvement compared to the older one, with which it was entirely unclear if we are setting the value of upstream *to* what is given as an option, or setting the upstream *for* what is given on the command line.