1
**查看Ruby源**
gem sources -l
(**删除Ruby源**
gem sources --remove https://rubygems.org/)
2
**替换Ruby源**
gem source -a https://gems.ruby-china.com/
3
**安装CocoaPods**
sudo gem install cocoapods
4
**部署CocoaPods**
pod setup
5
**创建podfile文件**
touch Podfile
6
**编辑podfile文件**
Vim Podfile
7
**输入podfile**
platform:ios,'9.0'
target 'MVVMTest' do
pod 'AFNetworking','~> 3.2.1'
end
(**查找三方库**
pod search AFNetworking)
8
**安装**
Pod install