Thursday, July 30, 2009

update rubygems

I tried to update rubygems on CentOs but could not.
First, I asked help to my friend Google and found this site:
It worked well on one computer but on another one I had this error:
in 'report_activate_error': could not find RubyGem session (>= 0) (Gem::LoadError)

I tried many things until I realized that "session" is actually a gem!
So let's do:
gem install session

Another error "could not find RubyGem hoe-seattlerb..."
So let's do:
gem install hoe-seattlerb

Same error with "hoe". But this one is tricky, because hoe need rubygems > 1.3.1, but to install rubygems 1.3.5 we need hoe!

in `report_activate_error’: Could not find RubyGem hoe (>= 2.3.0) (Gem::LoadError)

gem install hoe
ERROR: Error installing hoe:
hoe requires RubyGems version >= 1.3.1

I tried to do (wihout success):
gem install rubygems-update #by default, it installs the latest version which is 1.3.5 now

The problem is in version 1.3.5! First remove all rubygems:
gem uninstall rubygems-update

gem install rubygems-update -v 1.3.4

#Then you can install hoe
gem install hoe

I lost so many hours for this stupid mistake...