1

I am trying to update to Ruby 2.3.1. I downloaded from here, and did:

./configure
make
sudo make install

Then I got:

/home/sawa/Downloads/ruby-2.3.1/lib/rubygems/installer.rb:227:in `check_executable_overwrite': no implicit conversion of nil into String (TypeError)

How can I fix this and upgrade Ruby?

It turns out that Ruby is installed. But Ever since this happened, I have problem updating the gems. I get:

sudo gem update --system
Updating rubygems-update
ERROR:  While executing gem ... (TypeError)
no implicit conversion of nil into String

How can I fix that?

4

2 回答 2

1

This seems to be a bug in bundled version of rubygems, as existing variable really can be nil, try patching that line like in newer rubygems:

question << (existing || 'an unknown executable')
于 2016-04-26T16:51:43.663 回答
1

First of all, Locate the version of Rubygem that you want to remove in the gem directory in your system and delete it.

Then, Download the updated version rubygem file from here

Then, from your cmd, navigate to the download directory where setup.rb is located.

type the following command on cmd

ruby setup.rb

That's all

Verify by checking the gem version with

gem -v
于 2016-08-05T02:43:38.010 回答