1. gem update --system

  2. gem -v

  3. gem sources --add https://gems.ruby-china.com/ --remove https://rubygems.org/

  4. gem sources -l

  5. sudo gem install cocoapods

  6. pod setup

  7. 配置清华大学镜像: https://mirrors.tuna.tsinghua.edu.cn/help/CocoaPods