cocoapods 版本升级错误

-- version



```

1.$ sudo gem update --system// 先更新gem,国内需要切换源

2.$ gem sources --removehttps://rubygems.org/

3.$ gem sources -ahttps://ruby.taobao.org

4./$ gem sources -l

\*\*\* CURRENT SOURCES \*\*\*https://ruby.taobao.org/

5.$ sudo gem install cocoapods// 安装cocoapods

6.$ pod setup




在cocoapods 执行

sudo gem install cocoapods

的时候出现  While executing gem ... (Gem::FilePermissionError)

You don't have write permissions for the /usr/bin directory.

改为 sudo gem install -n /usr/local/bin cocoapods  即可

你可能感兴趣的:(cocoapods 版本升级错误)