CocoaPods升级到1.8.0

更新第三方库时,提示我版本太低

查看当前cocoapods 版本

pod --verion

发现我当前版本为1.4.0,于是我去更新cocoapods

sudo gem update cocoapods

报错

ERROR:Whileexecuting gem ... (Gem::RemoteFetcher::FetchError) bad response Not Found404(https://gems.ruby-china.org/specs.4.8.gz)

原因:https://gems.ruby-china.org 服务域名更换了org变成com

移除gem源

gem sources --remove https://gems.ruby-china.org/

修改gem源

gem sources -a https://gems.ruby-china.com

升级cocoapods

sudo gem install -n /usr/local/bin cocoapods --pre

稍等片刻,大概一分钟

再次查看版本 //1.8.0.beta.1

pod --version 

你可能感兴趣的:(CocoaPods升级到1.8.0)