From: Jeff Garzik Date: Fri, 17 Jun 2005 23:51:35 GMT Subject: Re: git merging Message-ID: <42B36207.3020209@pobox.com> In-Reply-To: Linus Torvalds wrote: > Ok. The most likely reason is that your main branch is not a symlink to > ".git/refs/***" at all, but just a regular ".git/HEAD" file. This is definitely not the case; my .git/HEAD is _always_ a symlink. My git-switch-tree script, attached, demonstrates how .git/HEAD symlink is retargetted to the specified branch. My workflow depends on .git/HEAD being a symlink. I'll see if I can reproduce with the latest git. Jeff #!/bin/sh if [ "x$1" != "x" ] then if [ ! -f .git/refs/heads/$1 ] then echo Branch $1 not found. exit 1 fi ( cd .git && rm -f HEAD && ln -s refs/heads/$1 HEAD ) fi git-read-tree -m HEAD && git-checkout-cache -q -f -u -a