赞
踩
Set up a mirror of the source repository. This implies --bare. Compared to --bare, --mirror not only maps local branches of the source to local branches of the target, it maps all refs (including remote-tracking branches, notes etc.) and sets up a refspec configuration such that all these refs are overwritten by a git remote update in the target repository.
建立一个源码库的镜像。含义类似于 --bare。相比 --bare,–mirro不只是将 源本地分支映射到目标本地分支,实际上映射了所有的引用refs(包括remote-tracking分支,注释等)并且建立指定性引用refspec 配置,即是说通过这次git远程更新,目标仓库的所有引用refs都会被覆盖
$ git clone --mirror http://域名/分组/仓库名称.git
$ cd 仓库名称.git
$ git push --mirror http://新域名/新分组/新仓库名称.git
如果源代码库存在merge request操作,推到新的服务器后,会有类似提示:
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。