From: Jeff King Date: Tue, 21 Mar 2006 09:19:16 GMT Subject: Re: efficient cloning Message-ID: <20060321091916.GA17125@coredump.intra.peff.net> In-Reply-To: <7v4q1sgpet.fsf@assigned-by-dhcp.cox.net> On Tue, Mar 21, 2006 at 12:42:02AM -0800, Junio C Hamano wrote: > The reason I would like to avoid .git/remotes/$origin is because > it is designed to be Porcelainish thing. The underlying C-level > git-fetch-pack never sees it; instead the information fed to > C-level is prepared by the upper layer using that file. As far > as I understand, Cogito does not understand it either, except > that it ships with bash completion code that reads from > filenames there. Then why not create .git/refs/remotes/$origin/HEAD at the time of clone (or later)? Then the core looks for: (current order, .git/refs, etc) .git/refs/remotes/foo .git/refs/remotes/foo/HEAD The porcelain can take care of managing the contents of HEAD. If there is no HEAD in the directory, then it cannot be looked up by 'foo' ('foo/remote-branch' must be used instead). -Peff