Git: Push a local git submodule, including submodule files, to a remote bare repository

不打扰是莪最后的温柔 提交于 2019-12-06 06:10:22

If B is actually a submodule, you should have a .gitmodule referencing it.
In that .gitmodule file, you would see the remote repo URL where B is pushed, in case there is any new commits done in B.

But B being a submodule means A won't have B files in it, only a reference to B SHA1.

If you want, you can un-submodule B (with my answer or this one) in order to keep all the B files in A.

A submodule has to have a separate repository. Create a new bare repo and push your submodule to it.

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