如何将git存储库与所有分支从bitbucket移动到github?
将所有分支和完整的历史记录从bitbucket移动到github的最佳方式是什么? 是否有脚本或我必须使用的命令列表?
您可以参考GitHub页面“复制存储库”
它用:
git clone --mirror
:克隆每个引用(提交,标记,分支) git push --mirror
:推动一切 这会给:
git clone --mirror https://bitbucket.org/exampleuser/repository-to-mirror.git
# Make a bare mirrored clone of the repository
cd repository-to-mirror.git
git remote set-url --push origin https://github.com/exampleuser/mirrored
# Set the push location to your mirror
git push --mirror
正如在LS评论中指出的那样:
Import Code
功能更容易。 请参阅https://github.com/new/import
这很简单。
1º在GitHub中创建一个新的空存储库(没有自述文件或licesne,您可以在之前添加它们),并且以下屏幕将显示
2º内部导入代码选项,你粘贴你的bitbucket网址的回购和voilà!
如果你在github上找不到“Import code”按钮,你可以:
url
。 它看起来像: 
Public
或Private
回购 Begin Import
更新:最近,Github宣布能够“用大文件导入存储库”
链接地址: http://www.djcxy.com/p/45187.html上一篇: How to move git repository with all branches from bitbucket to github?