1. 删除原gem源
gem sources --remove https://rubygems.org/
2.添加国内源
gem sources -a http://gems.ruby-china.com/
image
原因如图所示, 服务域名更换了,把gem sources -a https://gems.ruby-china.org/换成gem sources -a https://gems.ruby-china.com/即可。
3.打印是否替换成功
gem sources -l
4.安装高版本的pod
sudo gem install cocoa pods
网友评论