Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Ruby version >= X is incompatible with current version

I have rbenv installed on my system and am trying to run the standard bundle install command within my ruby application now. I'm getting the following error though:

activesupport-5.0.1 requires ruby version >= 2.2.2, which is incompatible with the current version, ruby 1.9.3p484

I've checked everything on my end and am unsure where it's getting the old version of ruby 1.9.3... since I have 2.3.0 installed:

> rbenv versions
    system
  * 2.3.0 (set by /neo-main/.ruby-version)

> ruby --version
  ruby 2.3.0p0 (2015-12-25 revision 53290) [i686-linux]

> echo $PATH
  /root/.rbenv/shims:/root/.rbenv/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games

I've rebooted just to make sure there wasn't something stuck in memory or whatever too.

like image 936
Godzilla74 Avatar asked Feb 17 '17 19:02

Godzilla74


People also ask

Which is latest version of Ruby?

What is the latest Ruby version? Ruby 3.1. 0 is the Ruby latest version (3.1. 0 was released Dec 25, 2021).


1 Answers

Check where your bundle command is coming from; it's probably outside rbenv. Do a gem install bundler and then rerun eval "$(rbenv init -)" to pick up the new shim.

like image 50
Mark Reed Avatar answered Oct 08 '22 03:10

Mark Reed