-2

我是rails中的菜鸟。我尝试使用RVM. 红宝石已安装。但是当我尝试使用安装 rails 时gem install rails --version 4.0.0,我收到以下消息:

Successfully installed rails-4.0.0
Parsing documentation for rails-4.0.0
Done installing documentation for rails after 1 seconds


在那之后

rails -v
The program 'rails' is currently not installed.  You can install it by typing:
sudo apt-get install rails

我不知道是怎么回事。

4

3 回答 3

0

You can get full installation instructions for Rails from here

Also use Ruby 2.0.0 for rails 4

于 2013-07-30T09:40:48.673 回答
0

The current version of Rails is 4.0.0. You don't have to specify anything while installing. Just use:

gem install rails

Also, which version of ruby do you currently have install? The recommended version for rails 4 is Ruby 2.0.0. Can you run gem list and see if you can find Rails in the output?

Possible duplicate: Rails keeps telling me that it's not currently installed

于 2013-07-30T09:38:37.463 回答
0

你需要先使用红宝石:

rvm use ruby --install
gem install rails -v 4.0.0 

还要确保阅读 rvm 的输出 - 它会在出现问题时为您提供注释和警告

于 2013-07-30T17:32:26.030 回答