I'm on Mac OS X 10.6 Snow Leopard. I just updated my Ruby stuff using:
sudo gem update
Unfortunately, it broke everything. When I try to run a simple command in my website directory, like:
rails generate model User
It failed, with this error:
Could not find gem 'rails (= 3.0.3, runtime)' in any of the gem sources listed in your Gemfile. Try running
bundle install
.
So I tried running bundle install rails
. It succeeded! So I tried running rails
. It failed. So I tried getting the Rails version by entering:
rails -v
Which failed with this error:
Could not find rake-0.8.7 in any of the sources
Try runningbundle install
.
But not only did it fail, it also created an empty folder rails/ruby/1.8
in my website directory.
This is a complete disaster for me as I am just a beginner in Ruby and Ruby on Rails, and even in the Terminal. Any help would be MUCH appreciated. Thanks.