2009-07-27 130 views
3

我正尝试在我运行OS X Server的新XServe服务器上执行从cvs到svn的迁移。还有就是已经预先安装了OS X的错误是cvs2svn和DBM库之间的已知冲突:替代cvs2svn执行cvs迁移到svn

ERROR: cvs2svn uses the anydbm package, which depends on lower level dbm libraries. Your system has dbm, with which cvs2svn is known to have problems. To use cvs2svn, you must install a Python dbm library other than dumbdbm or dbm. See http://python.org/doc/current/lib/module-anydbm.html for more information.

我跟所有的cvs2svn FAQ规定的步骤,但错误依然存在。有谁知道完成这项任务的另一种方式,或另一个网站为这个看似普遍的问题提供了不同的解决方案?

+0

相关http://stackoverflow.com/questions/ 922750 – 2012-01-10 00:12:25

回答

7

由于CVS和Subversion版本库实际上只是文件集合,解决此问题的一种方法可能是将CVS存储库复制到可以成功运行cvs2svn的机器,运行它以转换为Subversion,然后复制新的存储库返回到您的服务器。此方法的附加好处是,在执行此转换步骤时,您不会冒着意外地搞乱服务器配置的风险。

1

您总是可以使用例如手动方式手动安装其他dbm库。 MacPorts的。

0

也许听起来有点疯狂或过于夸张,但考虑使用'git'(例如MacPorts版本)。它克隆完整的CVS历史并将其推送到Subversion存储库中。下面的步骤应该做的工作(看看命令的手册,git help'cmd'):

 
    port install git-core cvs cvsps svn (if necessary) 

    create directory for git and init cvs git repo (let´s say ´cd ~/cvsgit´): 
    git cvsimport -v -d CVSROOT module 

    create new subversion repository (svnadmin) with trunk, tags, branches 
    now import this new repository to a git repository: 
    git svn clone -s file:///path/to/svnrepo (without trunk, tags, branches) 
    this creates a svnrepo directory; rename and move it to e.g. ~/svngit 

    now add the cvs git repo to svn repo: 
    cd ~/svngit 
    git remote add cvsrepo ~/cvsgit 
    git fetch cvsrepo 

    now merge the cvs master branch to the local svn master branch: 
    git merge remotes/cvsrepo/master 

    finally commit to (real) svn repository: 
    git svn dcommit 

你完成了!

+1

但请注意,git-cvsimport已知会转换除最琐碎的CVS存储库以外的所有严重问题:http://marc.info/?l=git&m=123626637729412&w=2 – mhagger 2009-07-28 08:58:24

3

cvs2svn本身是MacPorts的这么用,而不只是DBM库,你可以安装使用cvs2svn的MacPorts:

port install cvs2svn 

如果尚未安装,它还将安装的python2.5的版本MacPorts的和其他依赖关系。这并没有什么坏处,但需要一点时间和一点额外的空间。优点是你应该有一个工作,支持的版本,而不必打击进一步的依赖问题。

1

如果你已经安装了subversion,你确定你的系统变量的路径设置正确吗?

我有我的同样的问题,我最后不得不加入PYTHON_HOME和路径变量使用

C:\ Pyton27 \