From: Junio C Hamano Date: Sun, 05 Aug 2007 17:54:08 GMT Subject: Re: [PATCH] Fix install-doc-quick target Message-ID: <7vzm15eukf.fsf@assigned-by-dhcp.cox.net> In-Reply-To: Johannes Schindelin writes: > I do not like the behaviour "be stupid and assume cwd to be the working > tree root, if GIT_DIR is set and GIT_WORK_TREE is not". > > It bears _all_ kind of stupid connotations. Just imagine what would > happen with "git --git-dir=. add .". > > IMHO the new behaviour is _better_, since you can not shoot yourself in > the foot so easily. Being able to safeguard against doing a work tree > operation inside the git directory is a direct and elegant consequence of > defaulting to $GIT_DIR/.. in case $GIT_DIR ends in "/.git", and no work > tree if $GIT_DIR does _not_ end in "/.git". > > The semantics "if GIT_DIR is set, just assume the cwd to be the work tree > root unilaterally" is _broken_ as far as I am concerned. I am not disputing that. I was just pointing out that this is a change in semantics and we need to advertise it as such, and more importantly, advise people how to adjust to the new (and improved) world order.