我看过有类似问题的人,但每个人都只是说“谢谢你的帮助”,而没有详细说明他们是如何解决问题的。我对编程完全陌生。
基本上我的 $ gem list 输出给出:
*** LOCAL GEMS ***
actionmailer (3.2.6)
actionpack (3.2.6)
activemodel (3.2.6)
activerecord (3.2.6)
activeresource (3.2.6)
activesupport (3.2.6)
arel (3.0.2)
builder (3.0.0)
bundler (1.1.4)
erubis (2.7.0)
hike (1.2.1)
i18n (0.6.0)
journey (1.0.4)
json (1.7.3)
mail (2.4.4)
mime-types (1.19)
multi_json (1.3.6)
polyglot (0.3.3)
rack (1.4.1)
rack-cache (1.2)
rack-ssl (1.3.2)
rack-test (0.6.1)
rails (3.2.6)
railties (3.2.6)
rake (0.9.2.2)
rdoc (3.12)
rubygems-bundler (1.0.3)
rvm (1.11.3.4)
sprockets (2.1.3)
thor (0.15.3)
tilt (1.3.3)
treetop (1.4.10)
tzinfo (0.3.33)
但是当我输入 $ rails -vi 时得到:
user@ubuntu:~$ rails -v
The program 'rails' is currently not installed. You can install it by typing:
sudo apt-get install rails
其他一些线程说这是一个路径问题,但我不知道如果我摆弄 .bash 或路径并且觉得我需要有人通过这个 =/ 握住我的手我在做什么。
我的 echo $PATH 输出是:
user@ubuntu:~$ echo $PATH
/usr/lib/lightdm/lightdm:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin/bin:/usr/games:/home/user/.rvm/bin
$ gem 环境输出:
user@ubuntu:~$ gem environment
RubyGems Environment:
- RUBYGEMS VERSION: 1.8.24
- RUBY VERSION: 1.9.3 (2012-04-20 patchlevel 194) [x86_64-linux]
- INSTALLATION DIRECTORY: /home/user/.rvm/gems/ruby-1.9.3-p194
- RUBY EXECUTABLE: /home/user/.rvm/rubies/ruby-1.9.3-p194/bin/ruby
- EXECUTABLE DIRECTORY: /home/user/.rvm/gems/ruby-1.9.3-p194/bin
- RUBYGEMS PLATFORMS:
- ruby
- x86_64-linux
- GEM PATHS:
- /home/user/.rvm/gems/ruby-1.9.3-p194
- /home/user/.rvm/gems/ruby-1.9.3-p194@global
- GEM CONFIGURATION:
- :update_sources => true
- :verbose => true
- :benchmark => false
- :backtrace => false
- :bulk_threshold => 1000
- "install" => "--no-rdoc --no-ri"
- "update" => "--no-rdoc --no-ri"
- REMOTE SOURCES:
- http://rubygems.org/
如果我的问题格式不正确或不清楚,我深表歉意。我对编程和这个网站完全陌生。