Reputation: 3796
I just tried to downgrade my ruby on rails environment from 1.9.3 to 1.8.7
I have successfully updated Ruby! However I am now trying to update "rails".
when I run, I get the following error. How do I fix this?
$ gem install rails
ERROR: Error installing rails:
activesupport requires Ruby version >= 1.9.3.
thanks
IF I run $ gem install rails --debug I get the following:
Exception `Gem::LoadError' at c:/Ruby187/lib/ruby/site_ruby/1.8/rubygems/dependency.rb:298 - Could n
Exception `LoadError' at c:/Ruby187/lib/ruby/site_ruby/1.8/rubygems/core_ext/kernel_require.rb:55 -
Exception `LoadError' at c:/Ruby187/lib/ruby/site_ruby/1.8/rubygems/core_ext/kernel_require.rb:141 -
Exception `Win32::Registry::Error' at c:/Ruby187/lib/ruby/1.8/win32/registry.rb:397 - The system can
Exception `Win32::Registry::Error' at c:/Ruby187/lib/ruby/1.8/win32/registry.rb:397 - The system can
Exception `Win32::Registry::Error' at c:/Ruby187/lib/ruby/1.8/win32/registry.rb:397 - The system can
Exception `Win32::Registry::Error' at c:/Ruby187/lib/ruby/1.8/win32/registry.rb:397 - The system can
Exception `Win32::Registry::Error' at c:/Ruby187/lib/ruby/1.8/win32/registry.rb:397 - The system can
Exception `Win32::Registry::Error' at c:/Ruby187/lib/ruby/1.8/win32/registry.rb:397 - The system can
Exception `Win32::Registry::Error' at c:/Ruby187/lib/ruby/1.8/win32/registry.rb:397 - The system can
Exception `Win32::Registry::Error' at c:/Ruby187/lib/ruby/1.8/win32/registry.rb:397 - The system can
Exception `Win32::Registry::Error' at c:/Ruby187/lib/ruby/1.8/win32/registry.rb:397 - The system can
Exception `Win32::Registry::Error' at c:/Ruby187/lib/ruby/1.8/win32/registry.rb:397 - The system can
Exception `Win32::Registry::Error' at c:/Ruby187/lib/ruby/1.8/win32/registry.rb:397 - The system can
Exception `Win32::Registry::Error' at c:/Ruby187/lib/ruby/1.8/win32/registry.rb:397 - The system can
Exception `Win32::Registry::Error' at c:/Ruby187/lib/ruby/1.8/win32/registry.rb:397 - The system can
Exception `Win32::Registry::Error' at c:/Ruby187/lib/ruby/1.8/win32/registry.rb:397 - No more data i
Exception `Errno::EEXIST' at c:/Ruby187/lib/ruby/1.8/fileutils.rb:243 - File exists - c:/Users/Adam/
Exception `Resolv::DNS::Config::NXDomain' at c:/Ruby187/lib/ruby/1.8/resolv.rb:495 - _rubygems._tcp.
Exception `Resolv::DNS::Config::NXDomain' at c:/Ruby187/lib/ruby/1.8/resolv.rb:495 - _rubygems._tcp.
Exception `Resolv::ResolvError' at c:/Ruby187/lib/ruby/1.8/resolv.rb:459 - DNS result has no informa
Exception `Errno::EEXIST' at c:/Ruby187/lib/ruby/1.8/fileutils.rb:243 - File exists - c:/Ruby187/lib
Exception `Gem::InstallError' at c:/Ruby187/lib/ruby/site_ruby/1.8/rubygems/installer.rb:543 - activ
ERROR: Error installing rails:
activesupport requires Ruby version >= 1.9.3.
Upvotes: 0
Views: 303
Reputation: 34175
Ruby 1.8.7 is no longer supported., its highly discouraged to use 1.8.7 as you won't receive any security updates.
As a result, latest stable version of rails - v4.1 requires ruby 1.9.3 or higher. if for some reason, you still want to use old, out-dated & unsupported version of ruby. you have to use a older version of rails:
$ gem install rails -v 3.2
But I would encourage you to upgrade to latest ruby 2.1.2 as its MUCH MUCH faster & better.
Upvotes: 1
Reputation: 28
"activesupport requires Ruby version >= 1.9.3."
But you just said you downgraded your version of ruby to 1.8.7. Surely you need to update ruby back to your original version of 1.9.3 to update rails.
Also listed on http://ubyonrails.org/download :-
"We recommend Ruby 2.1.0 for use with Rails. We stopped supporting Ruby 1.8.x after Rails 3.2. Ruby 1.9.2+ will be supported until Rails 5."
Upvotes: 0