cocoapods 升级

查看CocoaPods版本

$ pod --version

命令行更新(安装)步骤【更新】

$ sudo gem update --system // 先更新gem,国内需要切换源
$ gem sources --remove https://rubygems.org/
$ gem sources -a https://ruby.taobao.org/
$ gem sources -l\*\*\* CURRENT SOURCES \*\*\*https://ruby.taobao.org/
$ sudo gem install cocoapods // 安装cocoapods
$ pod setup

在运行 sudo gem install cocoapods 的时候出现问题:```
ERROR: While executing gem ... (Errno::EPERM)
Operation not permitted - /usr/bin/xcodeproj


则可以改为:
`sudo gem install -n /usr/local/bin cocoapods`

你可能感兴趣的:(cocoapods 升级)