1)安装过cocoapods, 那么输入 : sudo gem install -n /usr/local/bin cocoapods
当然 上个步骤解决了我的 难题
2)首先在终端输入 gem sources -l 查看源, 将所有源移除 gem sources -r 源(如http://ruby.taobao.org/)
然后添加: gem sources -a https://ruby.taobao.org/
再安装cocoapods: sudo gem install cocoapods