/usr/local/rvm/bin
我在 Ubuntu 12.10 上安装了多用户版本的 RVM 。当我将 Ruby 从 1.9.3 升级到 2.0.0 时,这似乎导致每当我执行rvm version
或类似命令时弹出以下错误消息:
$ rvm version
Warning! PATH is not properly set up, '/usr/local/rvm/gems/ruby-2.0.0-p247/bin' is not at first place,
usually this is caused by shell initialization files - check them for 'PATH=...' entries,
it might also help to re-add RVM to your dotfiles: 'rvm get stable --auto-dotfiles',
to fix temporarily in this shell session run: 'rvm use ruby-2.0.0-p247'.
rvm 1.22.16 (stable) by Wayne E. Seguin <wayneeseguin@gmail.com>, Michal Papis <mpapis@gmail.com> [https://rvm.io/]
我已经尝试过类似问题中列出的建议rvm get head
,但rvm get head --auto-dotfiles
没有帮助。
我的最后有以下内容.bashrc
:
PATH=$PATH:/usr/local/rvm/bin # Add RVM to PATH for scripting
我的路径是:
$ echo $PATH
./bin:/usr/local/sbin:/usr/local/bin:/usr/local/rvm/gems/ruby-2.0.0-p247/bin:/usr/local/rvm/gems/ruby-2.0.0-p247@global/bin:/usr/local/rvm/rubies/ruby-2.0.0-p247/bin:/usr/local/rvm/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games
$ which rvm
/usr/local/rvm/bin/rvm
$ which ruby
/usr/local/rvm/rubies/ruby-2.0.0-p247/bin/ruby