Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

RVM not recognizing .ruby-version

Tags:

ruby

rvm

My application has the following files:

.ruby-version

ruby-2.0.0-p247

.ruby-gemset

app1

When I switch into the application directory the application does not recognize the new version. It switches Ruby versions but the application does not see that until I run rvm use ruby-2.0.0-p247 manually. It works fine with .rvmrc but not .ruby-version. My RVM is version 1.25.15.

Edit

It's a Rails 4 app and it's using the bin directory for executables.

like image 560
Artem Kalinchuk Avatar asked Jan 21 '14 20:01

Artem Kalinchuk


2 Answers

Check if you have a .rvmrc file in your project root folder.

You might need to update or remove it.

like image 161
Lucas Caton Avatar answered Sep 28 '22 17:09

Lucas Caton


I had the same problem after a fresh install. The problem was , that the rvm source script was not running . It started to work after i run this:

source /home/myuser/.rvm/scripts/rvm

To solve this permanently. Open your terminal and run this:

echo "source /home/myuser/.rvm/scripts/rvm" >> ~/.bashrc
like image 24
kröte Avatar answered Sep 28 '22 18:09

kröte