Error:
1、ERROR: SSL verification error at depth 0: certificate has expired (10) ERROR: Certificate /C=CN/ST=ZheJiang/L=HangZhou/O=Alibaba (China) Technology Co., Ltd./CN=*.taobao.org expired at 2018-12-05T03:16:02Z
原因:淘宝源证书过期了,已无法使用
解决方案:
<1> 移除淘宝源:gem source --remove https://ruby.taobao.org (注意:若你使用的是淘宝源,否则移除无效,步骤3 可查看当前源)
<2> 添加新的源:gem sources -a https://gems.ruby-china.org/
<3> 查看是否更新成功:gem sources -l


相关问题
1、若步骤2提示:Error fetching https://gems.ruby-china.org/: bad response Not Found 404
原因:由于域名备案导致,改用gem sources -a https://gems.ruby-china.com/
2、ERROR: While executing gem ... (Gem::FilePermissionError) You don't have write permissions for the /Library/Ruby/Gems/2.3.0 directory.
原因:gem install cocoapods导致
改用:sudo gem install -n /usr/local/bin cocoapods


其他终端命令
更新cocopods版本:gem install cocoapods
查看版本:pod --version

01-19 02:30