Re: DWIM "git checkout frotz" to "git checkout -b frotz origin/frotz"
- From
- Bruce Stephens <bruce.stephens@isode.com>
- Date
- Jun 7, 2010, 19:52 UTC
- Message-ID
- <80631uboye.fsf@tiny.isode.net>
- In-Reply-To
- <20100607193226.GA19789@localhost>
Clemens Buchacher <drizzd@aon.at> writes:
[...]
> "git checkout <branch>", on the other hand, will create a branch > based on a remote branch, even though you neither asked for a new > branch, nor did you specify any remote at all.
Provided such a branch doesn't already exist and that only one remote matches. I agree it's magic (and understand why people might not like it) but personally I find it convenient.
Possibly (because it hides the distinction between local and remote branches a little) it would be better opt-in than the default, but I think a reasonable case could be made in both directions.
[...]