更新CocoaPods 报错bad response Not Found 404

之前添加国内ruby源 gem sources --add https://gems.ruby-china.org
报错:

ERROR:  Could not find a valid gem 'cocoapods' (>= 0), here is why:
 Unable to download data from http://gems.ruby-china.org - bad response Not Found 404 (https://gems.ruby-china.org/specs.4.8.gz)

原因是 ruby-china 更换了域名https://gems.ruby-china.com

命令替换为

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

解决

猜你喜欢

转载自blog.csdn.net/weixin_34128237/article/details/87474698