already exists in the index

在 github 上面 clone 一个包含有 submodule 的 repo 的时候,用如下命令更新 submodule:

git submodule update --remote --merge

一直没法更新,尝试重新 add submodule,比如:

git submodule add  https://github.com/cisco/openh264 open_source_code/openh264

一直报如下错误:

open_source_code/openh264 already exists in the index

执行如下命令,解决此问题:

git rm -r --cached open_source_code/openh264

文章来自:http://my.oschina.net/jerikc/blog/513039
© 2021 jiaocheng.bubufx.com  联系我们
ICP备案:鲁ICP备09046678号-3