通过RVM安装Ruby失败

第一次安装失败是由于Homebrew一直安装不成功,遂去http://brew.sh/index_zh-cn.html官网

通过

/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

复制到终端中直接安装,安装成功后再通过RVM安装Ruby还是失败,根据提示输入brew doctor查找原因,发现时Xcode版本过低,更新安装之后并运行Xcode,再通过

rvm install 2.3.0

 安装了Ruby,安装Ruby成功后输入按照常规步骤到

pod repo remove master出现如下错误

[!] repo master does not exist

尝试更换源,输入如下

 pod repo add master http://git.oschina.net/akuandev/Specs.git出现如下错误

[!] To setup the master specs repo, please run `pod setup`.

切换源失败,根据提示输入pod setup

刚开始尝试很多次,都是如下错误

Setting up CocoaPods master repo

[!] /usr/local/bin/git clone https://github.com/CocoaPods/Specs.git master

 

Cloning into 'master'...

error: RPC failed; curl 56 SSLRead() return error -9806

fatal: The remote end hung up unexpectedly

fatal: early EOF

fatal: index-pack failed

 通过网络查询很久后死马当活马医,很多人遇到

error: RPC failed; curl 56 SSLRead() return error -36

输入

 sudo xcode-select -switch /Applications/Xcode.app/Contents/Developer就能pop setup成功

遂在终端输入如上

 再进行pod setup,结果如下

Setting up CocoaPods master repo

 

CocoaPods 1.1.0.rc.2 is available.

To update use: `sudo gem install cocoapods --pre`

[!] This is a test version we'd love you to try.

 

For more information, see https://blog.cocoapods.org and the CHANGELOG for this version at https://github.com/CocoaPods/CocoaPods/releases/tag/1.1.0.rc.2

 

Setup completed 有了绿色的Setup completed即可

最后成功安装好Ruby

 

注:确保安装了Xcode命令行工具,忘记是在哪一步安装了此工具,在终端输入

xcode-select --install  即可安装,

转载于:https://www.cnblogs.com/igeniuswwh/p/5946081.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值