[1.8.0] Change branch --set-uptream to take an argument

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Proposal:

Currently it is very easy to misinvoke --set-upstream if you assume it
takes an argument:

e.g.

  (master)$ git branch --set-upstream origin/master
  Branch origin/master set up to track local branch master.

In order to make its usage unambiguous, and to allow it to be used w/o
specifying the current branch, require it to take an argument like so:

  (master)$ git branch --set-upstream=origin/master

(I've misinvoked it so often, I've had to train myself to always
invoke it this way: git branch master --set-upstream origin/master)

Risks:

Hands which have become trained to use it as it currently is, scripts, etc.

Migration plan:

Introduce the new syntax to the man page and git branch for 1.7.x and
emit a warning whenever the current syntax is used. In 1.8, break the
current syntax.

(Though I'm not sure whether the options parser allows for both
--set-upstream and --set-upstream=<arg>)

j.
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]