iosxcodegitafnetworkingcocoapods

The dependency `AFNetworking (~> 2.5)` is not used in any concrete target


I want to install AFNetworking but I have a problem how can I fix and install? I used getting started with AFNetworking. https://github.com/AFNetworking/AFNetworking/wiki/Getting-Started-with-AFNetworking

$ sudo gem install cocoapods $ pod setup

$ touch Podfile $ open -a Xcode Podfile

source 'https://github.com/CocoaPods/Specs.git' platform :ios, '7.0' pod 'AFNetworking', '~> 2.5'


Solution

  • Add:

    target 'MyApp' do
      pod 'AFNetworking', '~> 2.5'
    end
    

    See: https://guides.cocoapods.org/using/the-podfile.html

    Then run pod install from the project directory.