将许多 CVS 模块转换为单个 SVN 存储库

发布于 2024-09-25 18:39:34 字数 310 浏览 0 评论 0原文

我有一个相当大的 CVS 存储库,我希望仅将少数模块转换为单个 Subversion 存储库。我已被正确引导使用 cvs2svn 进行转换,甚至已经构建了自己的选项文件。我不需要保留标签或分支,但我想保留修订历史记录。我的问题是我希望我的模块位于单个主干文件夹下,例如 svn/trunk/module1 和 svn/trunk/module2 而不是 svn/module1/trunk 和 svn/module2/trunk。当我将路径设置为空时,它会抛出有关路径为空的错误。有什么建议吗?

I have a rather large CVS repository that I am looking to only convert a handful of modules into a single Subversion repository. I have been correctly guided to using cvs2svn for the conversion and have even gotten as far as building my own options file. I do not need to retain tags or branches, but I would like to retain the revision history. My issue is that I want my modules to be under a single trunk folder, e.g. svn/trunk/module1 and svn/trunk/module2 instead of svn/module1/trunk and svn/module2/trunk. When I set the path to nothing it throws an error about the path being blank. Any suggestions?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

只涨不跌 2024-10-02 18:39:34

我的问题是我希望我的模块位于单个主干文件夹下,例如 svn/trunk/module1 和 svn/trunk/module2 而不是 svn/module1/trunk 和 svn/module2/trunk。 [...] 有什么建议吗?

为什么不按原样导入结构并稍后在存储库中移动内容?毕竟,移动事物的能力是 SVN 相对于 CVS 的最大优势之一。 (这种结构的变化在当时的历史中实际上可以被视为一个优势。)

My issue is that I want my modules to be under a single trunk folder, e.g. svn/trunk/module1 and svn/trunk/module2 instead of svn/module1/trunk and svn/module2/trunk. [...] Any suggestions?

Why don't you import the structure the way it is and move things around later in the repository? The ability to move things around is one of the greatest advantages of SVN over CVS, after all. (The fact that this change of structure is then in the history can actually be seen as an advantage.)

少女情怀诗 2024-10-02 18:39:34

最简单的方法是制作 CVS 存储库的副本,然后(在副本中)按照您希望它们最终出现在生成的 Subversion 存储库中的方式移动目录。然后转换为单个项目,将 cvs2svn 指向重新排列的存储库中的适当目录。例如:(

mkdir $CVSCOPY/proj
mv $CVSCOPY/path/to/module1 $CVSCOPY/proj/module1
mv $CVSCOPY/another/path/to/module2 $CVSCOPY/proj/module2
cvs2svn [OPTIONS] $CVSCOPY/proj

如果您的子模块已经按照所需的方式排列,则复制和重新排列可能甚至没有必要。)

The easiest thing to do is to make a copy of your CVS repository, then (in the copy) move the directories around the way you want them to end up in the resulting Subversion repository. Then convert as a single project, pointing cvs2svn at the appropriate directory within the rearranged repository. E.g.:

mkdir $CVSCOPY/proj
mv $CVSCOPY/path/to/module1 $CVSCOPY/proj/module1
mv $CVSCOPY/another/path/to/module2 $CVSCOPY/proj/module2
cvs2svn [OPTIONS] $CVSCOPY/proj

(If your submodules are already arranged in the desired way, the copying and rearranging might not even be necessary.)

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文