Git Clone: Not Working (old local repo push/pull works OK)

荒凉一梦 提交于 2020-01-07 07:45:05

问题


I have set me up a new repo on my server, I have it working with a push/pull on my local machine. I moved over to another computer today and tried to clone it but throws this error back at me:

MacBook-Pro:htdocs macbook$ git clone myuser@mysite.com:~/opt/git/myrepo.git
Cloning into 'myrepo'...
myuser@mysite.com's password:
remote: Counting objects: 8897, done.
remote: Compressing objects: 100% (7192/7192), done.
Write failed: Broken pipe89/8897), 260.00 KiB | 502.00 KiB/s
fatal: The remote end hung up unexpectedly
fatal: early EOF
fatal: index-pack failed

My git config on the server:

[core]
    repositoryformatversion = 0
    filemode = true
    bare = true
    sharedrepository = 1
[receive]
    denyNonFastforwards = true
[remote "origin"]
    fetch = +refs/heads/*:ref/remotes/origin/*
    url = ssh://mysshuser@mywebsite.com/~/opt/git/myrepot.git

[branch "master"]
    remote = origin
    merge = refs/heads/master

[branch "develop"]
    remote = origin
    merge = refs/heads/develop

I'm running git version 1.7.1


回答1:


Issue solved: git version caused issue. Updated to 1.8.5 on server to match local machine version.



来源:https://stackoverflow.com/questions/25005359/git-clone-not-working-old-local-repo-push-pull-works-ok

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!