Re: [PATCH] tone down the detached head warning
- From
Jeff King <peff@peff.net>
- Date
- Feb 1, 2007, 03:00 UTC
- Message-ID
- <20070201030030.GA1979@coredump.intra.peff.net>
- In-Reply-To
- <Pine.LNX.4.64.0701311907500.3021@xanadu.home>
On Wed, Jan 31, 2007 at 07:11:34PM -0500, Nicolas Pitre wrote:
Show 5 quoted lines
> No. This is misleading. > > You are _not_ on the remote tracking branch. You just happen to have > checked out a commit that came from a tracking branch, but you are still > detached from any branch at that point.
Sure, but that is a very subtle distinction that I doubt will make sense to git newbies. Having them check out what they consider to be a branch (and which is, in fact, a line of development -- just not one that you have locally marked as a head) and responding with "you are not on ANY branch" is a little off-putting.
Is there some text we can use that makes more sense in all situations?
I think part of the "scariness" of the message is that git-checkout does not _usually_ produce output. I wonder if, when switching HEAD, it usually printed "Now on branch <foo>", and for detached printed some special variant, it would seem more natural.
-Peff