简体   繁体   English

可可豆荚:豆荚安装问题

[英]Cocoa pods: Pod install issue

This is the content of my pod file. 这是我的pod文件的内容。

platform:ios, '5.0'

pod 'AFNetworking', :'~> 1.1.0'

When I try $pod install. 当我尝试$ pod安装。 I m getting following error. 我遇到以下错误。

 [!] Pod::Executable clone "https://github.com/AFNetworking/AFNetworking.git" "/Users/administrator/Library/Caches/CocoaPods/GitHub/a7f129229d47b74a225e1e2ed0bc604f35d71ac7" --mirror

Cloning into bare repository '/Users/administrator/Library/Caches/CocoaPods/GitHub/a7f129229d47b74a225e1e2ed0bc604f35d71ac7'...
fatal: unable to access 'https://github.com/AFNetworking/AFNetworking.git/': Failed connect to github.com:443; Operation timed out

It's blocking me to proceed. 它阻止了我继续前进。 What is the issue? 有什么问题

You are using Old version of AFNetworking. 您正在使用旧版本的AFNetworking。 because it have deployment target is 5.0. 因为它的部署目标是5.0。 and the Mac os version is 10.7. Mac OS版本是10.7。

Spec: 规格:

Pod::Spec.new do |s|
  s.name     = 'AFNetworking'
  s.version  = '1.1.0'
  s.license  = 'MIT'
  s.summary  = 'A delightful iOS and OS X networking framework.'
  s.homepage = 'https://github.com/AFNetworking/AFNetworking'
  s.authors  = { 'Mattt Thompson' => 'm@mattt.me', 'Scott Raymond' => 'sco@gowalla.com' }
  s.source   = { :git => 'https://github.com/AFNetworking/AFNetworking.git', :tag => '1.1.0' }
  s.source_files = 'AFNetworking'
  s.requires_arc = true

  **s.ios.deployment_target = '5.0'**
  s.ios.frameworks = 'MobileCoreServices', 'SystemConfiguration'

  **s.osx.deployment_target = '10.7'**
  s.osx.frameworks = 'CoreServices', 'SystemConfiguration'

  s.prefix_header_contents = <<-EOS
#ifdef __OBJC__
#import <Availability.h>
#if __IPHONE_OS_VERSION_MIN_REQUIRED
  #import <SystemConfiguration/SystemConfiguration.h>
  #import <MobileCoreServices/MobileCoreServices.h>
#else
  #import <SystemConfiguration/SystemConfiguration.h>
  #import <CoreServices/CoreServices.h>
#endif
#endif /* __OBJC__*/
EOS
end

so should be use update version https://github.com/AFNetworking/AFNetworking/wiki/Getting-Started-with-AFNetworking 因此应使用更新版本https://github.com/AFNetworking/AFNetworking/wiki/Getting-Started-with-AFNetworking

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM