Installed Rails But the Rails Command Says It's Not Installed

Installed Rails but the rails command says it's not installed

As others say, this may very well be a PATH variable issue on your bashrc/bash_profile file.

You can learn how to change PATH..

You can get the current PATH variable by typing echo $PATH

Rails keeps telling me that it's not currently installed

I had this problem today. Not completely related to your question, but since this page is what comes up in Google when I search for "Rails is not currently installed on this system", I thought I would add my answer:

What happened is that I was using ruby 1.9.2 with rails for a while, but then I needed to use ruby 1.8.7 to run some other script that I found.

Afterwards, I wanted to change by system back to using 1.9.2, and that's where the problem started:

$ rvm list

=> ruby-1.8.7-p352 [ x86_64 ]
ruby-1.9.2-p290 [ x86_64 ]

$ rvm use 1.9.2

I thought that would do the trick. But no, that gives me the "Rails is not currently installed on this system" message.

What I had forgotten is that I had configured rails using an rvm gemset. So I needed to specify the correct gemset when I was selecting which ruby version to make active.

$ rvm gemset list_all

gemsets for ruby-1.8.7-p352 (found in /Users/asgeo1/.rvm/gems/ruby-1.8.7-p352)
global

gemsets for ruby-1.9.2-p290 (found in /Users/asgeo1/.rvm/gems/ruby-1.9.2-p290)
global
rails31

$ rvm use ruby-1.9.2-p290@rails31

That did the trick.

Rails command not available after installing with gemfile

So, I was running rbenv rehash and setting the environment variable. However, the new env variables were not available until after a restart. Using the full path to /.rbenv/shims/rake solved the problem.

Rails: Command not Found after successful install

I'm certain that your problem was caused by gems in the other gem directory, here:

/root/.gem/ruby/1.9.1

So for future readers, look in your other GEM PATHS.

(And then if that's wrong I'll update this answer appropriately.)



Related Topics



Leave a reply



Submit