本文介绍了试图让svn2git在Windows上工作的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在将SVN存储库迁移到Git。 git-svn命令不能正确处理分支和标记,但是我偶然发现了一个名为svn2git的工具,它似乎解决了这个问题(https://github.com/nirvdrum/svn2git)。



我试着在Windows上设置这个工具,但我没有取得太大的成功。



我将svn2git安装复制到C:\svn2git并下载Ruby for Windows(http://rubyinstaller.org/),并将它保存在C: \Ruby193。



运行svn2git时返回了

  / bin / env:ruby:没有这样的文件或目录

然后我将Ruby的bin和lib文件夹复制到svn2git的bin和$ lib文件夹。



运行svn2git然后返回

 < internal:gem_prelude>:1:在'require'中:无法加载这样的文件 - < internal:gem_prelude>中的rubygems.rb(LoadError):1:在<编译>'

有谁知道如何在Windows环境下工作?谢谢

解决方案

显然, ruby​​gems.rb 缺失。按照文档中的说明安装它:



然后,按照以下指示安装 svn2git



After那样,一切都会好的。

I'm migrating an SVN repository over to Git. The git-svn command doesn't handle the branches and tags properly but I stumbled across a tool called svn2git which seems to resolve this (https://github.com/nirvdrum/svn2git).

I've tried setting up this tool to work on Windows but I've not had much success.

I started off by copying the svn2git installation to C:\svn2git and downloading Ruby for Windows (http://rubyinstaller.org/) and saved it at C:\Ruby193.

Running svn2git came back with

/bin/env: ruby: No such file or directory

I then copied Ruby's bin and lib folders to svn2git's bin and lib folders respectively.

Running the svn2git then came back with

<internal:gem_prelude>:1:in `require': cannot load such file -- rubygems.rb (LoadError) from <internal:gem_prelude>:1:in `<compiled>'

Does anyone know how to get this working on Windows environment? Thanks

解决方案

Obviously, rubygems.rb is missing. Install it as documented here:
https://rubygems.org/pages/download

Then, install svn2git as instructed here:
https://github.com/nirvdrum/svn2git

After that, everything shall be fine.

这篇关于试图让svn2git在Windows上工作的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-13 14:52