From: Petr Baudis Date: Thu, 17 May 2007 11:30:28 GMT Subject: Re: [PATCH] Git.pm: Add remote_refs() git-ls-remote frontend Message-ID: <20070517113028.GN4489@pasky.or.cz> In-Reply-To: <7vk5v89ek8.fsf@assigned-by-dhcp.cox.net> On Thu, May 17, 2007 at 07:58:31AM CEST, Junio C Hamano wrote: > Petr Baudis writes: > > > .... Too bad that > > > > git-ls-remote --heads . > > > > is subtly different from > > > > git-ls-remote . refs/heads/ > > > > so we have to provide the interface for specifying both. > > I've already heard you say the above elsewhere, but I am not > sure what you exactly mean here. Mind substantiating it a bit > more clearly? Because the arguments are matched like case "/$path" in */$pat ) so if you have remote "refs" and refs/remote/refs/heads/x, git-ls-remote refs/heads/ is ambiguous. OTOH, --heads always match start of the path. It's somewhat obscure and probably doesn't really matter for user interface, but API should be free even of obscure misbehaviour, I believe. -- Petr "Pasky" Baudis Stuff: http://pasky.or.cz/ Ever try. Ever fail. No matter. // Try again. Fail again. Fail better. -- Samuel Beckett