由于部分swift3.0的框架需要 CocoaPods 1.1.0 以上才支持,以前使用的是淘宝的镜像,但是只能升到 1.0.1版本,接下来就开始了苦逼的CocoaPods更新之路~~~
1.由于以前使用的淘宝源不再更新,先替换 镜像源
gem sources –remove https://ruby.taobao.org/
gem sources -a https://gems.ruby-china.org
2.验证是否 替换成功
gem source -l
成功后:
localhost:~ elion$ gem source -l
* CURRENT SOURCES *
3.升级 cocoa pods
sudo gem install -n /usr/local/bin cocoa pods
或
sudo gem install cocoapods
结果报错
ERROR: While executing gem … (Gem::DependencyError)
Unable to resolve dependencies: cocoapods requires cocoapods-core (= 1.2.0), cocoapods-downloader (< 2.0, >= 1.1.3), cocoap