Re: git checkout -b -t

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

 



John Tapsell <johnflux@xxxxxxxxx> writes:

> $ git checkout -t origin/mybranch
> fatal: git checkout: --track and --no-track require -b
>
> So they do exactly what it tells them:
> $ git checkout -b -t origin/mybranch
> Switched to a new branch "-t"
>
> doh
>
> How can we make this less easy for people to shoot themselves in the
> foot?

 (1) Explain things in terms of semantics, not in terms of "brainless
     cut&paste" operations.

 (2) Avoid telling them what to do in the error messages, instead why what
     they did is an error.

E.g. "--track/--no-track does not make sense if you are not creating a new
branch" would be far less confusing in this particular case.
--
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]