# Git 操作
# Git Submodule 流程
# 初始化仓库
git clone --recurse-submodules < git repo address >
1
2
2
# 初始化子模块
git submodule init
git submodule update --init
1
2
3
2
3
# 删除远程分支
git push origin --delete <branchName>
1
2
2
# 所有子模块切换 master 分支
git submodule foreach git checkout <branchName>
1
2
2
# 所有子模块更新 master 分支
git submodule foreach git pull
1
2
2
# 所有子模块打版本号
git submodule foreach git tag V1.2.4
1
2
2
# 推送所有 local tag
git submodule foreach git push --tags --> -->
1
2
2