记录一下关于 CocoaPods podfile 文件配置
pod 'PonyDebugger', :source => 'https://github.com/CocoaPods/Specs.git'
podspec文件中定义的所有默认subspecs。subspec:pod 'QueryKit/Attribute'
or
pod 'QueryKit', :subspecs => ['Attribute', 'QuerySet']
pod 'AFNetworking', :path => '~/Documents/AFNetworking'
注意,本地私有库中的,podspec文件必须在该文件夹中。
指定源,默认是master分支
pod 'AFNetworking', :git => 'https://github.com/gowalla/AFNetworking.git'
指定其他分支
pod 'AFNetworking', :git => 'https://github.com/gowalla/AFNetworking.git', :branch => 'dev'
使用tag
pod 'AFNetworking', :git => 'https://github.com/gowalla/AFNetworking.git', :tag => '0.7.0'
特殊的commit
pod 'AFNetworking', :git => 'https://github.com/gowalla/AFNetworking.git', :commit => '082f8319af'
podspec文件应该位于存储库的cocopods 存放的根目录中,如果这个库的存储库中还没有podspec文件,可以从其它来源获得:
pod 'JSONKit', :podspec => 'https://example.com/JSONKit.podspec'