git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: cant get git to work over http

From
Johannes Schindelin <johannes.schindelin@gmx.de>
Date
Feb 19, 2008, 11:18 UTC
Message-ID
<alpine.LSU.1.00.0802191115440.30505@racer.site>
In-Reply-To
<e26d18e40802182309l693b2099wb42573aca7348091@mail.gmail.com>
Hi,
On Mon, 18 Feb 2008, Anatoly Yakovenko wrote:
Show 18 quoted lines
> > > *.*.*.*- foobar [18/Feb/2008:16:40:12 -0800] "PROPFIND /git/repo
> > > HTTP/1.1" 301 320
> >
> > Try adding a / at the end of the url you use for your repo.
> 
> ah cool, that was it.  The initial push seems to have worked,
> 
> $ git push -v upload master
> Pushing to http://aeyakovenko@myserver.com/git/repo/
> Getting pack list
> Fetching remote heads...
>   refs/
>   refs/tags/
>   refs/heads/
> 'refs/heads/master': up-to-date
> 
> 
> but i cant clone or just normally push and pull the repo.
That's not correct.  You can clone, push and pull the repo.
> $ git-pull
> fatal: 'origin': unable to chdir or not a git archive
> fatal: The remote end hung up unexpectedly

Since you did not clone from anywhere, the remote "origin" is not set. You will have to do that yourself:

	git remote add -f origin http://aeyakovenko@myserver.com/git/repo/
Show 9 quoted lines
> $ git-clone http://aeyakovenko@myserver.com/git/repo/ foobar
> Initialized empty Git repository in /home/aeyakovenko/projects/foobar/.git/
> cat: /home/aeyakovenko/projects/foobar/.git/refs/remotes/origin/master:
> No such file or directory
> /usr/bin/git-clone: line 450: cd:
> /home/aeyakovenko/projects/foobar/.git/refs/remotes/origin: No such
> file or directory
> fatal: : not a valid SHA1
> fatal: Not a valid object name HEAD

That smells like another "master"-less repository. Why do people do that? Isn't it just _easier_ and more _hassle-free_ to just accept that the initial branch is called "master"?

Hth, Dscho

Previous: Mike HommeyNext: Anatoly Yakovenko
Message 5 of 22 in “cant get git to work over http”
  1. Anatoly YakovenkoFeb 19, 2008
  2. Mike HommeyFeb 19, 2008
  3. Anatoly YakovenkoFeb 19, 2008
  4. Mike HommeyFeb 19, 2008
  5. Johannes SchindelinFeb 19, 2008
  6. Anatoly YakovenkoFeb 19, 2008
  7. Jon LoeligerFeb 19, 2008
  8. Anatoly YakovenkoFeb 19, 2008
  9. Johannes SchindelinFeb 19, 2008
  10. Anatoly YakovenkoFeb 19, 2008
  11. Johannes SchindelinFeb 19, 2008
  12. Anatoly YakovenkoFeb 19, 2008
  13. Johannes SchindelinFeb 19, 2008
  14. Jeff KingFeb 19, 2008
  15. Jon LoeligerFeb 19, 2008
  16. Anatoly YakovenkoFeb 19, 2008
  17. Jon LoeligerFeb 19, 2008
  18. Anatoly YakovenkoFeb 19, 2008
  19. Anatoly YakovenkoFeb 19, 2008
  20. Johannes SchindelinFeb 19, 2008
  21. Anton GladkovFeb 20, 2008
  22. Robert HainesFeb 20, 2008

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.