当我跑步时
./script/server
我收到以下错误消息,我似乎无法找到如何解决问题。该文件夹位于我的桌面上,是在运行MacOSX 10.8.3的新计算机上从SVN存储库结账。
/Users/martin/Desktop/[FOLDER NAME]/config/boot.rb:89:in `load_rubygems': undefined method `set_paths' for Gem:Module (NoMethodError)
from /Users/martin/Desktop/[FOLDER NAME]/config/boot.rb:52:in `load_initializer'
from /Users/martin/Desktop/[FOLDER NAME]/config/boot.rb:39:in `run'
from /Users/martin/Desktop/[FOLDER NAME]/config/boot.rb:11:in `boot!'
from /Users/martin/Desktop/[FOLDER NAME]/config/boot.rb:115:in `<top (required)>'
from /Users/martin/.rbenv/versions/2.0.0-p0/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:45:in `require'
from /Users/martin/.rbenv/versions/2.0.0-p0/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:45:in `require'
from ./script/server:2:in `<main>'
有没有人对如何修复/排除故障有任何想法?
如果我运行which -a ruby
,我会:
/Users/martin/.rbenv/shims/ruby
/Users/martin/.rbenv/shims/ruby
/Users/martin/.rbenv/shims/ruby
/Users/martin/.rbenv/shims/ruby
/Users/martin/.rbenv/shims/ruby
/usr/bin/ruby
rails -v
Rails 4.0.0
ruby -v
ruby 2.0.0p0 (2013-02-24 revision 39474) [x86_64-darwin12.3.0]
运行script/server
会出现不同的错误
/Users/martin/.rbenv/versions/2.0.0-p0/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:45:in `require': cannot load such file -- script/../config/boot (LoadError)
from /Users/martin/.rbenv/versions/2.0.0-p0/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:45:in `require'
from script/server:2:in `<main>'