Cocoapods:确定 pod 版本
Cocoapods: Determine pod version
您如何知道 a) 您正在使用哪个版本的 Pod 以及 b) 如何更改它?
我在使用 SwiftyJSON 时遇到了一些编译错误,我想知道这是否是因为我使用的版本比我预期的要新。
播客文件:
source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '8.0'
use_frameworks!
target ‘XXX’ do
pod 'SwiftyJSON', :git => 'https://github.com/SwiftyJSON/SwiftyJSON.git'
.......
end
检查您的 Podfile.lock
文件。正如文档所说:
This file is generated after the first run of pod install, and tracks the version of each Pod that was installed.
要将版本更改为 2.2
已安装的 pod 使用:
pod 'SwiftyJSON', '2.2.0'
和运行
pod install
希望对你有帮助
您如何知道 a) 您正在使用哪个版本的 Pod 以及 b) 如何更改它?
我在使用 SwiftyJSON 时遇到了一些编译错误,我想知道这是否是因为我使用的版本比我预期的要新。
播客文件:
source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '8.0'
use_frameworks!
target ‘XXX’ do
pod 'SwiftyJSON', :git => 'https://github.com/SwiftyJSON/SwiftyJSON.git'
.......
end
检查您的 Podfile.lock
文件。正如文档所说:
This file is generated after the first run of pod install, and tracks the version of each Pod that was installed.
要将版本更改为 2.2
已安装的 pod 使用:
pod 'SwiftyJSON', '2.2.0'
和运行
pod install
希望对你有帮助