3

I want to use ruby 2.3.4 for my rails application which I have installed using rvm on Ubuntu 16.04.

after using command rvm list.

rvm rubies =* ruby-2.3.4 [ x86_64 ] # => - current # =* - current && default # * - default 

but when i use ruby -v I get.

ruby 2.5.0p0 (2017-12-25 revision 61468) [x86_64-linux]

so I used rvm --default use 2.3.4.

which does change the version to 2.3.4 when I check using ruby -v but when I restart the terminal or system it changes back to 2.5.0

I want to know how to include 2.5.0 into rvm or remove it.

8
  • Remove the system-wide version with sudo apt-get remove ruby. Commented Mar 3, 2018 at 8:13
  • @mudasobwa tried that but I get Package 'ruby' is not installed, so not removed Commented Mar 3, 2018 at 8:48
  • 2
    Then check you have no rbenv or any other concurrent ruby version manager installed. Commented Mar 3, 2018 at 9:03
  • Can you see if this works - stackoverflow.com/questions/26867714/… Commented Mar 3, 2018 at 9:35
  • 2
    Can you see where Ruby 2.5.0 is installed, use which ruby Commented Mar 3, 2018 at 11:37

1 Answer 1

3

Check that .bash_profile contains below lines:

[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm" # Load RVM into a shell session *as a function* 

Check .bashrc, .zshrc, .mkshrc file contains below lines at end of file:

export PATH="$PATH:$HOME/.rvm/bin" 

if not then,

First Run below command then follow link to install rvm:

rm -rf ~/.rvm 

RVM Install

Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.