I've been trying to upgrade my rails environment on my MacBook and I've messed something up, but I'm not sure what. Is it possible to completely remove RVM, Ruby and Rails and start from scratch? I'm quite confused at how this is all supposed to work.
I've currently got Ruby 1.8.7 and 1.9.2 installed via RVM. I had rails upgraded to 3.0.9 but it refuses to work now, citing some error with rake.
/Users/Moshe/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/site_ruby/1.9.1/rubygems/dependency.rb:247:in
to_specs': Could not find rails (>= 0) amongst [rake-0.8.7, rake-0.8.7, rubygems-update-1.8.5] (Gem::LoadError) from /Users/Moshe/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/site_ruby/1.9.1/rubygems/dependency.rb:256:in
to_spec' from /Users/Moshe/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/site_ruby/1.9.1/rubygems.rb:1182:ingem' from /Users/Moshe/.rvm/rubies/ruby-1.9.2-p180/bin/rails:18:in
'
What can I do to fix the situation? I'd like to revert to the version of ruby that came with my Mac.
(Edit: I'm on Snow Leopard 10.6.8)
Edit2:
I've now gotten rvm to run ruby 1.9.2 and rails 3.0.9 However, trying to boot the server using rails server
returns the following:
AppMachineMobile:hello Moshe$ rails server
=> Booting WEBrick
=> Rails 3.0.9 application starting in development on http://0.0.0.0:3000
=> Call with -d to detach
=> Ctrl-C to shutdown server
Exiting
/Users/Moshe/Development/Ruby/hello/config/initializers/new_rails_defaults.rb:14: undefined method `generate_best_match=' for ActionDispatch::Routing:Module (NoMethodError)
from /Library/Ruby/Gems/1.8/gems/activesupport-3.0.9/lib/active_support/dependencies.rb:235:in `load'
from /Library/Ruby/Gems/1.8/gems/activesupport-3.0.9/lib/active_support/dependencies.rb:235:in `load'
from /Library/Ruby/Gems/1.8/gems/activesupport-3.0.9/lib/active_support/dependencies.rb:225:in `load_dependency'
from /Library/Ruby/Gems/1.8/gems/activesupport-3.0.9/lib/active_support/dependencies.rb:596:in `new_constants_in'
from /Library/Ruby/Gems/1.8/gems/activesupport-3.0.9/lib/active_support/dependencies.rb:225:in `load_dependency'
from /Library/Ruby/Gems/1.8/gems/activesupport-3.0.9/lib/active_support/dependencies.rb:235:in `load'
from /Library/Ruby/Gems/1.8/gems/railties-3.0.9/lib/rails/engine.rb:201
from /Library/Ruby/Gems/1.8/gems/railties-3.0.9/lib/rails/engine.rb:200:in `each'
from /Library/Ruby/Gems/1.8/gems/railties-3.0.9/lib/rails/engine.rb:200
from /Library/Ruby/Gems/1.8/gems/railties-3.0.9/lib/rails/initializable.rb:25:in `instance_exec'
from /Library/Ruby/Gems/1.8/gems/railties-3.0.9/lib/rails/initializable.rb:25:in `run'
from /Library/Ruby/Gems/1.8/gems/railties-3.0.9/lib/rails/initializable.rb:50:in `run_initializers'
from /Library/Ruby/Gems/1.8/gems/railties-3.0.9/lib/rails/initializable.rb:49:in `each'
from /Library/Ruby/Gems/1.8/gems/railties-3.0.9/lib/rails/initializable.rb:49:in `run_initializers'
from /Library/Ruby/Gems/1.8/gems/railties-3.0.9/lib/rails/application.rb:134:in `initialize!'
from /Library/Ruby/Gems/1.8/gems/railties-3.0.9/lib/rails/application.rb:77:in `send'
from /Library/Ruby/Gems/1.8/gems/railties-3.0.9/lib/rails/application.rb:77:in `method_missing'
from /Users/Moshe/Development/Ruby/hello/config/environment.rb:5
from /Users/Moshe/Development/Ruby/hello/config.ru:3:in `require'
from /Users/Moshe/Development/Ruby/hello/config.ru:3
from /Library/Ruby/Gems/1.8/gems/rack-1.2.3/lib/rack/builder.rb:46:in `instance_eval'
from /Library/Ruby/Gems/1.8/gems/rack-1.2.3/lib/rack/builder.rb:46:in `initialize'
from /Users/Moshe/Development/Ruby/hello/config.ru:1:in `new'
from /Users/Moshe/Development/Ruby/hello/config.ru:1
/usr/bin/ruby
exist on your system? If so, perhaps your$PATH
variable needs to be updated? – Brian