views:

370

answers:

3

I'm trying to install rails using the following command:

$ sudo gem install rails --source http://gems.rubyonrails.org

But this is what i'm getting:

WARNING:  RubyGems 1.2+ index not found for:
        http://gems.rubyonrails.org/

RubyGems will revert to legacy indexes degrading performance.
ERROR:  While executing gem ... (Gem::Package::FormatError)
    No metadata found!

Any help will be appreciated!

A: 

When I run the command it just tries to reinstall 2.3.1. I was trying to upgrade yesterday ;)

Matt Darby
+1  A: 

Do you have at least gem version 1.3.1? It's required for Rails 2.2+.

Michiel de Mare
A: 

There might be a problem with your current sources. First, check the list of source by doing:

$ gem env | grep \"sources\"

Then, remove any non-standard repository:

$ sudo gem sources -r http://my_nonstandard_source.com

Then try to install it again:

$ sudo gem install rails --source http://gems.rubyonrails.org

Hopefully that'll be enough.

Federico Builes