我如何git-cvsimport从一个CVS存储库,有不同的分支多个模块? [英] How can I git-cvsimport multiple modules from a CVS repository, with differing branches?
问题描述
for 每个($ MODULE,$ BRANCH);做
git-cvsimport -px -v -d$ CVS_REPO$ MODULE-o$ BRANCH-C$ MODULE
完成
但是,为每个模块创建了一个不同的git存储库。我如何将它们合并为一个,如果这甚至是可能的?解析方案
理论上,您可以使用 git grafts 将您的存储库合并为一个:
$ git gradle b $ b参见有没有一种干净的方式来处理两个原始的git仓库,以相同的内容开始?
实际上,你可能想看看另一个工具如 cvs2git ,并检查它是否不导入分支以更一致的方式。
I'm trying to git-cvsimport
several different modules from CVS, all of which are on different branches.
So far I've done this (in pseudo-bash code):
for each ($MODULE, $BRANCH); do
git-cvsimport -p x -v -d "$CVS_REPO" "$MODULE" -o "$BRANCH" -C "$MODULE"
done
But that makes a different git repository for each module. How would I merge them all into one, if that's even remotely possible?
In theory, you could use git grafts to merge your repositories into one:
See "Is there a clean way to handle two original git repositories that started with the same content?"
In practice, you might want to look at another tool like cvs2git, and check if it does not import branches in a more consistent way.
这篇关于我如何git-cvsimport从一个CVS存储库,有不同的分支多个模块?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!