Git同时推送到多个远程仓库

Posted by 石福鹏 on 2019-07-17
Estimated Reading Time 1 Minutes
Words 72 In Total
Viewed Times

1、关联本地仓库到多个远程分支

1
2
3
git remote add github https://github.com/shifpeng/octopus.git

git remote add gitee https://gitee.com/ArkPlan/octopus.git

2、切换检出分支

1
git checkout test

3、合并该分支到当前分支

例如:合并develop到test

1
git merge develop

4、push

1
2
3
git push gitee test

git push github test

如果您喜欢此博客或发现它对您有用,则欢迎对此发表评论。 也欢迎您共享此博客,以便更多人可以参与。 如果博客中使用的图像侵犯了您的版权,请与作者联系以将其删除。 谢谢 !