How do you downgrade rubygems?
Updated November 2011: Now that RVM's out, try running rvm install rubygems <version>
.
How do I downgrade to an old version of compass using gem install?
sudo gem install compass --version versionnumber
What's the proper way to downgrade a gem?
gem "factory_girl", "2.0.0.rc1", :group => :test
in your gem file, and then run
bundle update factory_girl
How to downgrade bundler or upgrade rails?
Try the following commands:
gem uninstall bundler
gem install bundler --version '1.0.0'
How to downgrade application from Ruby 2.0.0 to 1.9.3
Do a commit in what ever versioning system you are using so you can roll back if needed. You should also update your ruby 1.9.3 to the latest 1.9.3-484.
rvm get stable
rvm upgrade 1.9.3
Uninstall your json gem
gem uninstall json
It may warn about dependencies, that should be OK since you will reinstall. Now bundle:
bundle install
You may have to do this with other gems until any that have different versions or dependencies based on the ruby version are installed in that environment.
edit
Since it isn't working for you and I can create a Rails 4.0.2 app on Ruby 1.9.3-p484 and run the server with json(1.8.1) just fine I would try this:
Create a new directory for your project, cd
into that directory, then set rvm to use the right ruby:
rvm use ruby-1.9.3-p484
then install rails for that gem set
gem install rails
Now create a new rails app with the same name as your old one
rails new ....
Then copy all of your application's files over to the new rails app. I think you could just overwrite everything. Don't copy over the Gemfile.lock file. In the new app's directory run
bundle install
this should add any gems you are missing in the new environment's gem set.
Mismatched ruby version after downgrade from 2.4.1 to 2.3.3 while running bundle install
Gem installation is specific to ruby version, so the bundler
you're using is likely installed to your old ruby. Try installing bundler
again:
gem install bundler
That should fix your problem.
Related Topics
How to Define Action With Simple Form For
Rails.Cache Error in Rails 3.1 - Typeerror: Can't Dump Hash With Default Proc
Rspec: Expect VS Expect With Block - What's the Difference
How to Count Duplicates in Ruby Arrays
How to Install Rvm on Windows 7
What Are the Magic $-Prefixed Variables in Ruby
How to Assign Hash['A']['B']= 'C' If Hash['A'] Doesn't Exist
Rails Engines Extending Functionality
How to Run All Tests With Minitest
Controller Spec Unknown Keyword: Id
How to Remove the Bom from a Utf-8 Encoded File
Rake "Already Initialized Constant Wfkv_" Warning
How to Format the Value Shown in a Rails Edit Field
How to Sort an Array in Ruby to a Particular Order
"Gem Install Rails" Fails With Dns Error
Json Encoding Wrongly Escaped (Rails 3, Ruby 1.9.2)
"Certificate Verify Failed" Openssl Error When Using Ruby 1.9.3