Svn - >与几个干线/分支/标签的git迁移 [英] Svn -> git migration with several trunk/branches/tags
问题描述
我有一个SVN仓库,它包含以下当前结构: 该项目分为两个独立的子库(或任何你想要的) 有没有办法将这个迁移到git 而不会丢失历史? 编辑:我尝试了git svn clone,但是,正如我所想的那样,它没有遵循从旧结构转移到新结构。它只从新结构导入了修订版本。 首先,我将主干转换为git: 然后我转换每个项目: 然后对每个项目我使用移植和过滤分支从主干连接了以前的历史记录。 我只是博客有关。 I have a single SVN repository with the following current structure: which originally had this structure: That is, the project was split into two separate "subrepositories" (or whatever you want to call that) Is there any way to migrate this to git without losing history?
Would svn2git be better that git-svn for this scenario? Is there any other migration tool? EDIT: I tried git svn clone as suggested but, as I thought, it didn't follow the move from the old structure to the new one. It only imported the revisions from the new structure. First I converted the main trunk to git: Then I converted each project: Then for each project I attached the previous history from the main trunk using grafts and filter-branch. I just blogged about it. 这篇关于Svn - >与几个干线/分支/标签的git迁移的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
在这种情况下,svn2git会比git-svn更好吗?是否有其他迁移工具?
git svn clone url-to-project -s
git svn clone url-to-project1 -s
git svn clone url-to-project2 -s
...
git svn clone url-to-project -s
git svn clone url-to-project1 -s
git svn clone url-to-project2 -s
...