Git cloning error: 'fatal: multiple updates for … ref not allowed'

南笙酒味 提交于 2019-12-22 03:48:54

问题


I'm getting an error when trying to git clone a repository:

git clone https://github.com/laradock/laradock.git                                                 
Cloning into 'laradock'...                                                                           
remote: Enumerating objects: 8606, done.                                                             
remote: Total 8606 (delta 0), reused 0 (delta 0), pack-reused 8606                                  
Receiving objects: 100% (8606/8606), 8.09 MiB | 6.92 MiB/s, done.                                    
Resolving deltas: 100% (4551/4551), done.                                                            
fatal: multiple updates for ref 'refs/remotes/origin/LaraDock-ToolBox' not allowed

This is happening for any repo I try to clone. I am running git version 2.21.0 installed via homebrew.

Has anyone else encoutered this issue? Not really sure whats going on here...

Thanks!


回答1:


Well, I seem to have fixed the issue. Removing the following from my .gitconfig seemed to do the trick, but I am not sure why:

[remote "origin"]
    fetch = +refs/heads/*:refs/remotes/origin/*

I know that git v2.21.0 was just released a few days ago, so maybe something changed under the hood. I need to check out the release notes.

Anyways, hope this can help someone!



来源:https://stackoverflow.com/questions/54922704/git-cloning-error-fatal-multiple-updates-for-ref-not-allowed

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