1

I had used below mentioned commands to install rails in ubuntu 12.10

sudo apt-get update

sudo apt-get install curl

\curl -L https://get.rvm.io | bash -s stable

source ~/.rvm/scripts/rvm

rvm requirements

rvm install 1.9.3

rvm use 1.9.3 --default

rvm rubygems current

gem install rails

Every steps are doing good, but it works for terminal which we are installing rails. If we exit from the terminal and work on a new terminal then the following error occurs.

The program 'rails' can be found in the following packages: * rails * ruby-railties-3.2 Try: sudo apt-get install

I came through a solution that whenever I open an terminal I would run these cmd source ~/.rvm/scripts/rvm rvm --default use 1.9.3-p374

Can any one explain why these things happen??

Marek Lipka
  • 50,622
  • 7
  • 87
  • 91
Mothirajha
  • 1,033
  • 1
  • 10
  • 18

2 Answers2

1

Did you include the init script into your bash_profile/bashrc?

RVM installed by Ruby not working?

Community
  • 1
  • 1
BvuRVKyUVlViVIc7
  • 11,641
  • 9
  • 59
  • 111
0

I've installed Rails 3.2.9 on my machine with RVM. You can follow this steps:

  1. Install RVM : \curl -L https://get.rvm.io | bash -s stable
  2. Reload shell configuration & test: source ~/.rvm/scripts/rvm
  3. Install Ruby via RVM: rvm install 1.9.2 or rvm install 1.9.3
  4. Choose version Ruby after install: rvm use 1.9.2 or rvm use 1.9.3
  5. Ruby 1.9.2 and 1.9.3 support gem 1.8.25, so you'll install rails: gem install rails -v 3.2.9.

Done.

Note
Reload shell: source ~/.rvm/scripts/rvm and choose version Ruby rvm use 1.9.2 before work with projects.

vinhnguyen
  • 46
  • 4