RubyGems error on update: undefined local variable or method `remote_gemspecs'

Posted Posted by Wes in Ruby     Comments 4 comments
Nov
23

I updated rubygems:

>sudo gem update --system
Password:
Updating RubyGems
Updating rubygems-update
Successfully installed rubygems-update-1.3.1
ERROR:  While executing gem ... (NameError)
    undefined local variable or method `remote_gemspecs' for
   #<gem ::Commands::UpdateCommand:0x14df818>

… but received this error:

undefined local variable or method `remote_gemspecs'

Reading the release notes prompted me to install the rubygems-update gem separately:

>sudo gem install rubygems-update
Successfully installed rubygems-update-1.3.1

Finally, run the update_rubygems command to actually update:

>sudo update_rubygems
Installing RubyGems 1.3.1
mkdir -p /usr/local/lib/ruby/site_ruby/1.8
mkdir -p /usr/local/bin
install -c -m 0644 rbconfig/datadir.rb /usr/local/lib/ruby/site_ruby/1.8/rbconfig/datadir.rb
.... more installation

> gem -v
1.3.1

Finally!

4 Comments to “RubyGems error on update: undefined local variable or method `remote_gemspecs'”

  • Just what I needed. Thanks!

  • thanks a lot!

  • Just an fyi: I needed to do:

    >sudo update_rubygems

    instead of:

    >update_rubygems

    as you had it.

    Otherwise, perfect! :-)

  • Oh, good call. I updated the post appropriately.

Post comment

about databasically

We live and work in Kansas City, USA.

We're passionate about helping small businesses succeed and want to help you use technology to get more done.

From server, desktop, network management to programming custom web applications in Ruby on Rails, we're here to lend a hand.

Contact us if you have any questions!