0
在我Podfile安装,我有:ReachabilitySwift不能用的CocoaPods
pod 'ReachabilitySwift', '~> 3.0'
但是当我运行pod install
,所有的框架是正确设置,除了ReachabilitySwift:
Installing ReachabilitySwift 3 (was 2.4)
[!] Error installing ReachabilitySwift
[!] /usr/bin/git clone https://github.com/ashleymills/Reachability.swift.git /var/folders/cn/1zzgfkjj5xq3hm3g4351087r0000gn/T/d20170922-5156-v06cm4 --template= --single-branch --depth 1 --branch v3
Cloning into '/var/folders/cn/1zzgfkjj5xq3hm3g4351087r0000gn/T/d20170922-5156-v06cm4'...
warning: Could not find remote branch v3 to clone.
fatal: Remote branch v3 not found in upstream origin
有了这个GitHub link ,我找到了推荐的解决方案:
请加个
s.pod_target_xcconfig = { 'SWIFT_VERSION' => '3.0' }
到podspec文件。 否则,每个吊舱安装后都会出现错误。
但我不知道在哪里可以找到podspec文件以及在什么地方插入这个字符串。
我检查。在这种情况下,我将安装https://github.com/tonymillion/Reachability,而不是https://github.com/ashleymills/Reachability.swift。框架真的从ReachabilitySwift变成了Reachability。但是pod没有改变,所以奇怪的是我无法安装pod'ReachabilitySwift' –
@PaulT。检查我更新的答案。 – the4kman