[英]Rails Gem bundler not installed - even after I install it
For a Rails app, I tried running $ bundle install
. 对于Rails应用程序,我尝试运行$ bundle install
。 But, even after I ran $ gem install bundler
, I got the same message. 但是,即使在我运行$ gem install bundler
,我仍然收到相同的消息。
this is what happened: 这是发生了什么:
Run `bundle install` to install missing gems.
Davids-iMac-2:213calendar davidburton$ bundle install
ERROR: Gem bundler is not installed, run `gem install bundler` first.
Davids-iMac-2:213calendar davidburton$ gem install bundler
Successfully installed bundler-1.3.5
1 gem installed
Installing ri documentation for bundler-1.3.5...
Installing RDoc documentation for bundler-1.3.5...
Davids-iMac-2:213calendar davidburton$ bundle install
ERROR: Gem bundler is not installed, run `gem install bundler` first.
UPDATE1 更新1
rvm list
rvm rubies
ruby-1.9.2-p290 [ x86_64 ]
=* ruby-1.9.3-p374 [ x86_64 ]
# => - current
# =* - current && default
# * - default
Check your home directory for a ~/.bash_profile
file. 检查主目录中的~/.bash_profile
文件。
If it exists, and you don't remember creating it, copy its contents to ~/.bashrc
and remove the .bash_profile
file completely. 如果存在,并且您不记得创建它,请将其内容复制到~/.bashrc
并完全删除.bash_profile
文件。
By default, rvm appends the commands for updating path with rvm function in .bash_profile
after rvm
installation. 缺省情况下,安装rvm后, rvm
在.bash_profile
rvm
使用rvm功能更新路径的命令附加在.bash_profile
。 Ubuntu, at a time only uses .bash_profile
if it is present, or .bashrc
when .bash_profile
is absent. Ubuntu一次仅使用.bash_profile
如果存在),而仅使用.bashrc
如果不存在.bash_profile
)。 This results in PATH
not being correctly set, and the gem, even though installed, is not detected since it is not on your path. 这会导致PATH
设置不正确,并且即使安装了gem也不会检测到它,因为它不在您的路径中。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.