From: Mike Hommey Date: Thu, 29 Nov 2007 07:02:57 GMT Subject: Re: [PATCH] scripts: do not get confused with HEAD in work tree Message-ID: <20071129070257.GB5144@glandium.org> In-Reply-To: <7vbq9d29h3.fsf@gitster.siamese.dyndns.org> On Wed, Nov 28, 2007 at 04:15:04PM -0800, Junio C Hamano wrote: > When you have a file called HEAD in your work tree, many commands that > our scripts feed "HEAD" to would complain about the rev vs path > ambiguity. A solution is to form command line more carefully by > appending -- to them, which makes it clear that we mean HEAD rev not > HEAD file. Shouldn't this be done for anything else, then ? You could have a file with the same name as a branch and have some commands using branch names fail too. Mike