如何将具有历史记录的 SVN 存储库迁移到新的 Git 存储库? [英] How do I migrate an SVN repository with history to a new Git repository?

查看:25
本文介绍了如何将具有历史记录的 SVN 存储库迁移到新的 Git 存储库?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我阅读了 Git 手册、FAQ、Git - SVN 速成课程等,他们都解释了这个和那个,但你找不到像这样的简单说明:

I read the Git manual, FAQ, Git - SVN crash course, etc. and they all explain this and that, but nowhere can you find a simple instruction like:

SVN 仓库在:svn://myserver/path/to/svn/repos

Git 仓库在:git://myserver/path/to/git/repos

git-do-the-magic-svn-import-with-history 
svn://myserver/path/to/svn/repos 
git://myserver/path/to/git/repos

我不希望它那么简单,我也不希望它是一个单一的命令.但我确实希望它不会试图解释任何事情 - 只是说明在此示例中要采取的步骤.

I don't expect it to be that simple, and I don't expect it to be a single command. But I do expect it not to try to explain anything - just to say what steps to take given this example.

推荐答案

魔法:

$ git svn clone http://svn/repo/here/trunk

Git 和 SVN 的操作非常不同.你需要学习Git,如果你想跟踪SVN上游的变化,你需要学习git-svn.git-svn 主页有一个很好的例子部分:

Git and SVN operate very differently. You need to learn Git, and if you want to track changes from SVN upstream, you need to learn git-svn. The git-svn main page has a good examples section:

$ git svn --help

这篇关于如何将具有历史记录的 SVN 存储库迁移到新的 Git 存储库?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆