一、远程私有库的升级
1、 把新增的类 拖入到 classes 文件夹中 ;
2、 修改 pod.spec 文件的 s.verson = ‘0.2.0';
二、更新远程仓库
1、cd 到本地仓库的位置,执行以下操;
2、上传更新代码
git add .
git commit -m '更新描述'
git push origin master
3、版本更新这一步非常重要,为更新索引库做准备
//版本号要与 s.verson = ‘0.2.0'保持一致
git tag -a '新版本号' -m '注释'
git push --tags

四、验证远程Spec
//如果报错可能是你的文件错误,上传的时候一定要交验文件没有错误
pod spec lint —private
1、终端输出表示没有错误

2、远程索引库中有你的版本

五、更新远端和本地索引库
//pod repo push 索引库名称 xxx.podspec
pod repo push gitee-peter_zhang-mobilekitspec MobileKit.podspec
六、搜索下库pod search MobileKit
1、如果本地出现所有的新版本和旧版本就表示成功

2、pod search: 如果没有搜到 可以尝试一下操作
rm ~/Library/Caches/CocoaPods/search_index.json
七、团队协作用法
1、找到本地的podfile文件更改成最新版本0.3.0
#pod默认源
source 'https://github.com/CocoaPods/Specs.git'
source 'https://gitee.com/peter_zhang/MobileKitSpec.git'
#平台工程版本
platform :ios, '8.0'
target 'Ruter' do
#消除警告
inhibit_all_warnings!
#网络请求(warning~~ acceptableContentTypes加入@"text/html")
pod 'AFNetworking', '~> 3.1.0'
pod 'MobileKit', '~> 0.3.0'
end
2、
然后cd到podfile所在文件目录执行
然后看到控制台输出表示安装成功
