Please enable Javascript to view the contents

git submodule 使用

 ·  ☕ 1 分钟 · 👀... 阅读

演示

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

分享

幽梦
作者
幽梦
傻猪男孩

目录