【发布时间】:2018-10-23 10:12:44
【问题描述】:
我的 macbook 是 OSX El Capitan。它预装了 Apple 通用 Ruby 2.0.0 版。
现在,我想使用最新的 Ruby 2.3.0。我设法使用 rvm 来安装 Ruby 2.3.0。 rvm 完成安装 ruby 2.3.0 后,我看到以下消息:
Ruby was built without documentation, to build it run: rvm docs generate-ri
/Users/John/.rvm/bin/rvm: line 66: shell_session_update: command not found
Creating alias default for ruby-2.3.0...
* To start using RVM you need to run `source /Users/John/.rvm/scripts/rvm`
in all your open shell windows, in rare cases you need to reopen all shell windows.
我关注了这条消息,并运行命令
source /Users/John/.rvm/scripts/rvm
但是当我运行ruby -v 时,版本仍然是Apple 预装的Ruby 2.0.0。如何切换到我通过 rvm 安装的 ruby?
(在.rvm/rubies路径下我可以找到ruby-2.3.0)
【问题讨论】: