我正在研究使用rvm从ruby-1.8.7迁移到ruby-1.9.2的细节,我遇到了一个将宝石从一个ruby复制到另一个ruby的问题,我想看看是否有人知道交易是什么,以及为什么我会出错。
我已经安装了1.9.2,但是运行rvm gemset copy会抛出一个错误。
[22:11][adamstacoviak:~]$ rvm gemset copy ruby-1.8.7-p249 ruby-1.9.2-p180
Copying gemset from ruby-1.8.7-p249 to ruby-1.9.2-p180
cp: cannot overwrite directory /Users/adamstacoviak/.rvm/gems/ruby-1.9.2-p180/cache with non-directory /Users/adamstacoviak/.rvm/gems/ruby-1.8.7-p249/cache
Making gemset for ruby-1.9.2-p180 pristine.
ERROR: Error running 'rvm gemset pristine' under ,
please read /Users/adamstacoviak/.rvm/log/ruby-1.8.7-p249/gemset.pristine.log..。这是日志文件的内容。我也更新了bundler,因为我看到它提到找不到bundler-1.0.12。更新到bundler 1.0.12并没有起到作用。
[2011-04-12 22:09:54] rvm gemset pristine # under ruby-1.9.2-p180
ERROR: While executing gem ... (NameError)
uninitialized constant Gem::RemoteFetcher
Restoring gem(s) to pristine condition...
Cached gem for bundler-1.0.12 not found, attempting to fetch...
[2011-04-12 22:14:26] rvm gemset pristine # under ruby-1.9.2-p180
ERROR: While executing gem ... (NameError)
uninitialized constant Gem::RemoteFetcher
Restoring gem(s) to pristine condition...
Cached gem for bundler-1.0.12 not found, attempting to fetch...对于rvm gemset copy出错的原因有什么想法吗?
发布于 2011-04-13 12:25:05
只需将行添加到文件/usr/bin/gem (在mac上可能有所不同),在需要'rubygems‘之后需要'rubygems/gem_runner’。
Found this over here
发布于 2011-04-13 12:13:54
您可以只使用cp:
cp -R ~/.rvm/gems/ruby-1.8.7-p249/* ~/.rvm/gems/ruby-1.9.2-p180/https://stackoverflow.com/questions/5644047
复制相似问题