After updating RubyGems I got the following error message:
1 2 | /usr/bin/gem:10: undefined method `manage_gems' for Gem:Module (NoMethodError) # |
Nice. So I took a look at the output that was generated and came across this:
1 2 3 4 | Deprecation Notices: * Gem::manage_gems has been removed. * Time::today will be removed in RubyGems 1.4. |
Now what? Right – fix it.
1 | sudo vim /usr/bin/gem |
Search “Gem.manage_gems” and remove it or replace it with
1 | #Gem.manage_gems |
Unfortunately i got this
1 2 | /usr/bin/gem:23: uninitialized constant Gem::GemRunner (NameError) # |
when running the gems command. After “googling” I came up with this:
1 | sudo vim /usr/bin/gem |
inserting
1 | require 'rubygems/gem_runner' |
so that the first lines of /usr/bin/gem look like this
1 2 3 | require 'rubygems' require 'rubygems/gem_runner' #Gem.manage_gems |
Fixed.
Thx. It solved my problem.
Thanks!! It works for me too!
Thanks
=)
Thanks a lot man !
Thanks 2!!!
You’re my hero
Thanks a ton.
Great !
Problem solved on Ubuntu / ruby 1.86
Thanks !
Just what I was looking for!! Thank you very much.
Nice one, fixed my issue and allowed me to install a specific version of rails. Thank you!
Worked here too. Dumb bugs! hahah
That did the trick on Xubuntu 8.04. Thanks for the gem.
thank you for this fix. that saved my day!
Tnx!
Thank a lots
Thanks a bunch!
I really thanks for your effort on this. I also faced this problem. I went through your modification wherever is needed. It works fine for me. Thanks man.
Thanks a lot!
Respect!
Thanks! It worked for me too. Good on ya for sharing.
Thanks man! You rock
Thank’s that helped
Hmm, couldn’t you just replace /usr/bin/gem with /usr/bin/gem1.8? That’s what got installed by update_rubygems.
To fix it I just did:
sudo mv /usr/bin/gem1.8 /usr/bin/gem
thanks so much!!!
Thanks for the info!
very logical..: )
Thx!
Thanks a bunch!!
thx saved my day!
Thanks a lot for posting the solution to this issue!
Thanks!
Thanks!!
Yay, thanks.
Man, this is awesome. i saw this post previously, but blog theme is vired and I didn’t saw explanation text at all
Thanks, that’s what I was looking for.
Thanks ,very good to do
Thanks! it worked for me and I’m a total noob…
Didn’t. Ruby sucks.
Thanks! Muchas gracias!
Thanks. But how do you know this is the one that need to be written?
Very nice.