Dans mon PODFILE, j'ai:ReachabilitySwift ne peut pas être installé avec CocoaPods
pod 'ReachabilitySwift', '~> 3.0'
Mais quand je lance pod install
, tous les cadres sont configurés correctement, sauf 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
Avec cette GitHub link , J'ai trouvé une solution recommandée:
Veuillez ajouter un
s.pod_target_xcconfig = { 'SWIFT_VERSION' => '3.0' }
au fichier podspec. Sinon, il y aura une erreur après l'installation de chaque pod.
Mais je ne sais pas où trouver le fichier podspec et à quel endroit insérer cette chaîne.
J'ai vérifié. Dans ce cas, je vais installer https://github.com/tonymillion/Reachability, pas https://github.com/ashleymills/Reachability.swift. Le cadre a vraiment changé de ReachabilitySwift à Reachability. Mais les pods ne sont pas modifiés, donc c'est étrange que je ne puisse pas l'installer avec le pod 'ReachabilitySwift' –
@PaulT. Vérifiez ma réponse mise à jour. – the4kman