宝石安装错误需要Ruby版本

时间:2018-04-09 17:27:55

标签: ruby rubygems

使用ubuntu/trust64,我收到以下错误:

vagrant@vagrant-ubuntu-trusty-64:~/workspace/project$ bundle install
Fetching gem metadata from http://rubygems.org/.................
Fetching gem metadata from http://rubygems.org/..
Resolving dependencies.......................................................................
RubyGems 1.8.23 is not threadsafe, so your gems will be installed one at a time. Upgrade to RubyGems 2.1.0 or higher to enable parallel gem installation.
Using concurrent-ruby 1.0.5
Fetching i18n 1.0.0
Installing i18n 1.0.0
Gem::InstallError: i18n requires Ruby version >= 2.0.0.
An error occurred while installing i18n (1.0.0), and Bundler cannot continue.
Make sure that `gem install i18n -v '1.0.0'` succeeds before bundling.

In Gemfile:
  activesupport was resolved to 5.1.6, which depends on
    i18n

我不理解上述错误,因为据我所知,我ruby 2.4.3使用了2.0.0,大于vagrant@vagrant-ubuntu-trusty-64:~/workspace/project$ ruby -v ruby 2.4.3p205 (2017-12-14 revision 61247) [x86_64-linux-gnu]

View

请告诉我如何解决这个问题。

1 个答案:

答案 0 :(得分:0)

尝试运行这些命令

gem install rubygems-update
update_rubygems

我怀疑它可能是rubygems而不是你的ruby版本的问题。