Jeff King <peff@xxxxxxxx> writes: > On Mon, Jan 08, 2007 at 03:19:48AM -0800, Junio C Hamano wrote: > >> I decided to fast-track this one. With a handful fix-ups, this >> is now at the tip of 'next'. > > I haven't seen the code, waiting for kernel.org to mirror, but I have a > question... > >> The primary difference from the one we discussed, and then has >> been sitting in 'pu', is that coming back from the detached HEAD >> state is allowed only with '-f' or to a branch that is a >> fast-forward of HEAD. > > Hrm. So does that mean this doesn't work (without -f): > > git checkout v1.4.0 > ... look around ... > git checkout v1.2.0 That should work. The first checkout, because there is no branch v1.4.0, makes the HEAD detached. You are no longer on any branch at that point, and "git checkout v1.2.0" that follows do not trigger the check which is about "coming back from the detached HEAD state". But I would probably do the second v1.2.0 "checkout" with "git reset --hard", if what I am doing is "wandering, looking around to see different commits". - 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