Re: master^ is not a local branch -- huh?!?
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Jan 29, 2010, 20:48 UTC
- Message-ID
- <7veil8iqnj.fsf@alter.siamese.dyndns.org>
- In-Reply-To
- <fabb9a1e1001291235h26681e65qe4851cae1c536b6d@mail.gmail.com>
Sverre Rabbelier <srabbelier@gmail.com> writes:
Show 6 quoted lines
>> master^ is a commit (the first parent of master), not a branch (local >> or otherwise). > > Perhaps we should change the message to say "not a branch" if it's not > a reference to a remote branch? Or simply changing the text to "not a > (local) branch"?
I think "not a branch" is a good suggestion, whether the target of checkout is "master^" or "origin/topic".
These days, you can say "git checkout topic" to automagically create a local "topic" branch that forks from "origin/topic" remote tracking branch when you have one, thanks to Dscho's UI improvement ideas (one less reason you may end up on a detached HEAD state without wanting to).