Upgrading Ruby gems to 1.3.2 on Centos 5

centos ruby gems

Centos 5 are pretty restrictive when it comes to adding new packages into the repositories. So at times you have to circumvent the yum's and do the builds yourself. That is if you rely on the packages you download and compile.

Nevertheless I wanted to run install rake into my virtual environment, but when I tried with

$ sudo gem install rake
ERROR:  Error installing rake:
rake requires RubyGems version >= 1.3.2

so here the small recipe goes:

cd /tmp/
wget http://rubyforge.org/frs/download.php/55066/rubygems-1.3.2.tgz
tar xvzf rubygems-1.3.2.tgz 
cd rubygems-1.3.2
sudo ruby setup.rb

That should be it. Now it's okay to run

sudo gem install rake

And confirm it with

$ rake --version
rake, version 0.9.2