I'm trying to install Ruby on Rails using RVM. I am following this guide
http://ryanbigg.com/2010/12/ubuntu-ruby-rvm-rails-and-you/
I have just installed RVM, and used rvm install 1.9.2, but when I try to run ruby -v, I get this error
The program 'ruby' is currently not installed. You can install it by typing:
sudo apt-get install ruby
I am not sure whether or not to install ruby using apt-get. The tutorial mentions to avoid using apt-开发者_C百科get when installing ruby and stuff. Also, I installed ruby on RVM. I am confused, any help will be appreciated. Thanks in advance!
After you do rvm install 1.9.2
, you need to tell RVM to use that installed version of Ruby:
rvm use 1.9.2
To make this the default:
rvm use 1.9.2 --default
You may need to do a source ~/.bashrc
to update the changes, or even reboot/logout (Ubuntu sometimes doesn't fully reload everything until a complete reboot).
Try opening another terminal or run source .bash_profile
When you installed RVM, did you remember to add this line to your ~/.bash_profile and reload your shell?
[[ -s "$HOME/.rvm/scripts/rvm" ]] && . "$HOME/.rvm/scripts/rvm
精彩评论