I am going through this tutorial, but I already had Ruby 1.8.7 installed. I need to have 1.9.2/1.9.3 version.
I started to use RVM.
$ rvm list rubies
rvm rubies
ruby-1.8.7-p358 [ x86_64 ]
ruby-1.9.2-p318 [ x86_64 ]
=* ruby-1.9.2-p320 [ x86_64 ]
ruby-1.9.3-p194 [ x86_64 ]
# => - current
# =* - current && default
# * - default
but if I run ruby -v it returns still 1.8.7.
$ ruby -v
ruby 1.8.7 (2011-06-30 patchlevel 352) [x86_64-linux]
other return values:
$ whereis ruby
ruby: /usr/bin/ruby /usr/bin/ruby1.8 /usr/lib/ruby /usr/share/man/man1/ruby.1.gz
$ which rails
/usr/local/bin/rails
$ which ruby
/usr/bin/ruby
When you’re typing
rubyyou’re still hitting the system ruby, not the rvm ruby.Did you follow all the directions here: https://rvm.io//rvm/install/ ?
It looks like you’re running Linux — did you see this section in the rvm install docs?
Also,
rvmadds some lines to your.bashrcfile to load itself into memory whenever you open a console session. It looks like this may be your issue.In my
.bashrc, for example,rvminserted the following:Is there something similar in yours? Also, if you’re using z-shell you may need to take some extra steps that are outlined in the install docs.