I'm new to Ruby and Rails and I installed the latest beta version of Rails 4 on my Mac, before I installed RVM to manage my versions. The Rails 4 beta is becoming a huge pain in the ass because it's the default version in every new tab I open in the terminal. How can I uninstall the Rails 4 beta and all references to it?
相关问题
- Question marks after images and js/css files in ra
- Using :remote => true with hover event
- Eager-loading association count with Arel (Rails 3
- How to specify memcache server to Rack::Session::M
- Why am I getting a “C compiler cannot create execu
相关文章
- Ruby using wrong version of openssl
- Right way to deploy Rails + Puma + Postgres app to
- AWS S3 in rails - how to set the s3_signature_vers
- Difference between Thread#run and Thread#wakeup?
- how to call a active record named scope with a str
- How to add a JSON column in MySQL with Rails 5 Mig
- “No explicit conversion of Symbol into String” for
- form_for wrong number of arguments in rails 4
I had the same problem with Rails 4.0.0 final version. I used all what was mentioned before with no success. What helped was listing all my gems, I'm using Windows, so it was:
Then I checked the rails versions. It showed rails 3.2.14 (what I wanted) with railties 4.0.0, 4.0.0.rc2 and 3.2.14.
I then ran
and uninstalled all other versions except 3.2.14 and now it works well. The problem was that when Rails 3.2 installation is called, the latest (or all) versions of railties is installed.
Try:
or
and you will be asked which version to uninstall (if there are more than one).
Do
and choose the version 4 beta as the one to uninstall. Do not worry about unmatched dependencies at this point. Just say 'yes' to go ahead with the uninstall.
Once it is gone, do
This will get and install the latest released version for you.
Except of uninstalling rails you need to uninstall railties gem - rails exec is only wrapper that will select most up-to-date railties gem.
I had the same problem as ckarbass (Rails was still set at 4.0.0.rc1 when I entered
rails -v
). To solve it, I used Bernard Potocki's advice, but took into consideration that I had a different version.To make it possible for whatever version you may have, just do:
gem uninstall rails
Then, select the version of Rails 4 you have and delete it.
Then, do:
gem uninstall railties
And do the same thing.
When I uninstalled the Rails 4 version of railties, it told me that dependencies for a couple gems (coffee-rails and sass-rails) wouldn't be met. So I just did the same thing with both of them as I did above, and deleted their Rails 4 versions as well (for example, for sass-rails, I had a version installed called sass-rails-4.0.0.rc1).
And done! The terminal now lists 3.2.13 as my current Rails version.