views:

679

answers:

3

I can't seem to install the twitter gem in my shoes app.

When I try...

Shoes.setup do
  gem 'twitter'
end

require 'twitter'

I get

hoe requires RubyGems version >= 1.3.1

Is this a bug in Shoes or Hoe? Any ideas on a work-around?

A: 

I had this exact problem yesterday with a Rails application. The solution was to download and install RubyGems 1.3.1 from source. I used the command:

wget http://rubyforge.org/frs/download.php/45905/rubygems-1.3.1.tgz

John Topley
Didn't quite work for me. This is a Shoes app, which has a very different way of installing gems.
Scott
RubyGems are RubyGems. They have no knowledge of Shoes, Rails or any other framework.
John Topley
+2  A: 
sudo gem install rubygems-update # install the latest (1.3.5 at the moment)

or

sudo gem install rubygems-update -v 1.3.1 # or specifically 1.3.1

It also depends on what version your rubygems is on right now - sometimes you can't update directly to 1.3.5; you have to update to 1.3.1 before upgrading to the latest one.

Furthermore, it is generally recommended to install rubygems from source the first time, and update it using the above commands.

Ahsan Ali
First 1.3.1 and then latest, worked for me to update the rubygems that ship with Leopard OSX.
Adrian
+1  A: 

@ John Topley: RubyGems may not be aware of Shoes, but Shoes has its own way of handling RubyGems. It copies/installs them to its own directory, I've been told this is because Shoes includes its own Ruby interpreter