内容简介:RVM 使用指南
RVM 常用的命令整理
RVM 是一个命令行工具,可以提供一个便捷的多版本 Ruby 环境的管理和切换。 https://rvm.io/
我相信做为iOS开发者,对ruby的使用都是从安装ocoapods吧
注意:这里所有的命令都是再用户权限下操作的,任何命令最好都不要用 sudo.
RVM 安装
$ gpg --keyserver hkp://keys.gnupg.net --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 $ \curl -sSL https://get.rvm.io | bash -s stable $ source ~/.bashrc $ source ~/.bash_profile
修改 RVM 的 Ruby 安装源到 Ruby China 的 Ruby 镜像服务器,这样能提高安装速度
$ echo "ruby_url=https://cache.ruby-china.org/pub/ruby" > ~/.rvm/user/db
Ruby 的安装与切换
列出已知的 Ruby 版本
rvm list known
安装一个 Ruby 版本
rvm install 2.2.0 --disable-binary
切换 Ruby 版本
rvm use 2.2.0
如果想设置为默认版本,这样一来以后新打开的控制台默认的 Ruby 就是这个版本
rvm use 2.2.0 --default
查询已经安装的ruby
rvm list
卸载一个已安装版本
rvm remove 1.8.7
以上就是本文的全部内容,希望对大家的学习有所帮助,也希望大家多多支持 码农网
猜你喜欢:本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们。
The Sovereign Individual
James Dale Davidson、William Rees-Mogg / Free Press / 1999-08-26 / USD 16.00
Two renowned investment advisors and authors of the bestseller The Great Reckoning bring to light both currents of disaster and the potential for prosperity and renewal in the face of radical changes ......一起来看看 《The Sovereign Individual》 这本书的介绍吧!