Re: Problem with git fetch over http://
On Fri, 25 Apr 2008, John Wiegley wrote:
Show 21 quoted lines
> Hello, I'm using the Builtbot to pull sources from a Git repository, and have
> found that the Buildbot's Git step always uses git-fetch -- a detail of
> Buildbot which I currently have little control over.
>
> This is no problem if the git:// protocol is used, but using fetch with
> http:// doesn't work. This has been mentioned elsewhere:
>
> http://lists.berlios.de/pipermail/bitbake-dev/2007-November/000765.html
>
> Here's a quick example of what I mean:
>
> cd /tmp ; mkdir foo ; cd foo ; git init
>
> git fetch git://newartisans.com/ledger.git # works fine
>
> cd /tmp ; rm -fr foo ; mkdir foo ; cd foo ; git init
>
> git fetch http://newartisans.com/git/ledger.git # fails
>
> This is happening with git-1.5.5 on the server, Apache 2.2 and git-1.5.5.1 on
> the client.
John mentioned on IRC that clone works.
$ git-ls-remote http://newartisans.com/git/ledger.git 96751442d9eda537480867e599e4c604663f4530 refs/heads/master 365baca5174232cc35e4ed190fd8ce93c3611c84 refs/heads/v2.4.1 f972a89073843fdbb2a1bef969d9ca70509d4bfe refs/heads/v2.5 6a81d760dc4ab9028b27430124702c28c0b894ed refs/tags/cvs-20040410 fed3956a310a2ea8c8595b7fde7aaa0623492ca6 refs/tags/v0.1 ...
$ git-ls-remote git://newartisans.com/ledger.git 96751442d9eda537480867e599e4c604663f4530 HEAD 96751442d9eda537480867e599e4c604663f4530 refs/heads/master 365baca5174232cc35e4ed190fd8ce93c3611c84 refs/heads/v2.4.1 f972a89073843fdbb2a1bef969d9ca70509d4bfe refs/heads/v2.5 6a81d760dc4ab9028b27430124702c28c0b894ed refs/tags/cvs-20040410 fed3956a310a2ea8c8595b7fde7aaa0623492ca6 refs/tags/v0.1 ...
Looks like either server-info.c:update_info_refs() needs to also list HEAD, or transport.c:get_refs_via_curl() needs to guess that $url/HEAD exists and fetch it to add to the list, or both.
-Daniel
*This .sig left intentionally blank*