Git will not init/sync/update new submodules

后端 未结 21 2065
野趣味
野趣味 2020-12-12 13:11

Here\'s part of the contents of my .gitmodules file:

[submodule \"src/static_management\"]
        path = src/static_management
        url = gi         


        
21条回答
  •  执笔经年
    2020-12-12 13:54

    For the record:
    I created the same issue by adding an empty repository as submodule. In this case, there was no reference hash available for the submodule, leading to the error described by the original poster.

    Force-adding the repository after having committed to it solved the issue (as in Arvids post)
    git submodule add --force git@my-repo.git destination

提交回复
热议问题