2

Trying to install the 'less' gem. I type sudo gem install less as instructed at http://lesscss.org/, and I get the following error:

ERROR:  While executing gem ... (Gem::GemNotFoundException)
    Could not find less (> 0) in any repository

Alright, so I figure maybe I just need to update RubyGems. Trying 'gem update --system' gets me

Updating RubyGems...
Attempting remote update of rubygems-update
ERROR:  While executing gem ... (Gem::InstallError)
    rubygems-update requires builder >= 0

Arrgh. Alright, then let's try 'sudo gem install builder':

ERROR:  While executing gem ... (Gem::GemNotFoundException)
    Could not find builder (> 0) in any repository

Seems that no matter what gem I try to install, it can't be found in any repository. I check my environment, and rubyforge is listed:

RubyGems Environment:
  - VERSION: 0.9.4 (0.9.4)
  - INSTALLATION DIRECTORY: /usr/local/lib/ruby/gems/1.8
  - GEM PATH:
     - /usr/local/lib/ruby/gems/1.8
  - REMOTE SOURCES:
     - http://gems.rubyforge.org

Any idea what's going on? I'm on OSX 10.4, and I installed Ruby 1.8.6 before this.

Vadim Kotov
  • 8,084
  • 8
  • 48
  • 62
nullspace
  • 21
  • 2

4 Answers4

1

I think rubygems 1.3.x requires ruby 1.8.7 so you might install that first. Then update rubygems to 1.3.7. via gem update --system

Jed Schneider
  • 14,085
  • 4
  • 35
  • 46
0

The version of rubygems bundled in osx uses gemforge as its offical source of gems - this has since been replaced with gemcutter. You should be able to do

sudo gem update --system

To upgrade to update the latest version of ruby gems, which will then use gemcutter as the sources link

timmow
  • 3,595
  • 2
  • 23
  • 22
0

That's a really old version of rubygems! How did you install this?

Is it a manual install? If so, perhaps you could try a manual upgrade the same way.

Stéphan Kochen
  • 19,513
  • 9
  • 61
  • 50
-1

Do the following:

sudo gem update --system

to update your install of RubyGems. Then, add the Github gem repository to your sources. I suggest github because you'll find a lot of useful things there:

sudo gem sources -a http://gems.github.com
Mike Trpcic
  • 25,305
  • 8
  • 78
  • 114
  • 1
    github has stated that their gem hosting will end at the end of this year, so I wouldn't count on that forever. presently gemcutter.org/rubygems.org is the official repo of gems. – Jed Schneider Jul 16 '10 at 15:03