目录 演示 演示 1 2 3 4 5 6 7 8 9 添加父亲,也就是初始化git仓库 git init 添加儿子们,添加子模块 git submodule add https:xxx.com/xxx.git 找回儿子们,因为在clone主仓库的时候,git默认是不会把子模块给clone下来,所以需要使用以下命令 git submodule update --init --recursive