From: Andreas Ericsson Date: Mon, 12 Nov 2007 19:17:17 GMT Subject: Re: Cloning empty repositories, was Re: What is the idea for bare repositories? Message-ID: <4738A6BD.50704@op5.se> In-Reply-To: Johannes Schindelin wrote: > Hi, > > On Mon, 12 Nov 2007, Nicolas Pitre wrote: > >> On Mon, 12 Nov 2007, Johannes Schindelin wrote: >> >>> On Mon, 12 Nov 2007, Matthieu Moy wrote: >>> >>>> Johannes Schindelin writes: >>>> >>>>> On Mon, 12 Nov 2007, Jan Wielemaker wrote: >>>>> >>>>>> I found out that cloning a empty bare repository produces nothing >>>>>> at all, [...] >>>>> If they are empty, what exactly do you mean to clone? >>>> I'd expect an empty repository, with the git remote configured >>>> correctly. >>> Yeah, right. >>> >>> Last time I checked, those geneticists did not clone thin air. They >>> always waited until they had something to clone. >> But we're not geneticists, and I think the above usage should "just work >> (tm)". > > I am still convinced that it is not very intelligent to start your > development from a non-existing branch. > That's what happens with every new project though. The question is if something starts with making space for things to be in, or if it starts with things appearing in that space. > But since you're one of the people knowing git _internals_ pretty well, > here's another reason just for you why this cannot be done: There is no > way to find out where the HEAD points to. > $ mkdir foo; cd foo; git init; git symbolic-ref -q HEAD refs/heads/master -- Andreas Ericsson andreas.ericsson@op5.se OP5 AB www.op5.se Tel: +46 8-230225 Fax: +46 8-230231