我有以下安裝在Ubuntu 12沒有這樣的文件來加載 - 初始化(LoadError)
- 紅寶石1.9.2p320
- 的Rails 3.2.6
現在我已經老項目,該項目被顯影成軌道2 &紅寶石1.8.7
問題:
當我老項目的根目錄
ruby ./script/plugin install git://github.com/rails/rails_upgrade.git
下運行下面的命令跟隨誤差來
Invalid gemspec in [/usr/local/rvm/gems/ruby-1.9.2-p320/specifications/ZenTest-4.9.1.gemspec]: Illformed requirement ["< 2.1, >= 1.8"]
/usr/local/rvm/rubies/ruby-1.9.2-p320/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:55:in `require': no such file to load -- initializer (LoadError)
from /usr/local/rvm/rubies/ruby-1.9.2-p320/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:55:in `require'
from /var/www/project/client/softwallet/config/boot.rb:54:in `load_initializer'
from /var/www/project/client/softwallet/config/boot.rb:38:in `run'
from /var/www/project/client/softwallet/config/boot.rb:11:in `boot!'
from /var/www/project/client/softwallet/config/boot.rb:109:in `<top (required)>'
from <internal:lib/rubygems/custom_require>:29:in `require'
from <internal:lib/rubygems/custom_require>:29:in `require'
from ./script/plugin:2:in `<main>'
使用'rvm'。因此,當你使用舊項目工作時,通過'rvm use 1.8.7'將ruby版本更改爲舊版本,如果你使用新項目,則使用'rvm use 1.9.2'。這將消除任何不兼容問題。 – 2013-04-26 08:47:56
但是我想將rails 2項目升級到rails 3 – GBD 2013-04-26 08:50:15