Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Pod install displaying error in cocoapods version 1.0.0.beta.1

Tags:

ios

cocoapods

People also ask

How do you update a pod with CocoaPods?

When you run pod update SomePodName , CocoaPods will try to find an updated version of the pod SomePodName, without taking into account the version listed in Podfile. lock . It will update the pod to the latest version possible (as long as it matches the version restrictions in your Podfile).


You have to specify a target for each pod.

e.g. if before you had your Podfile written like this:

pod 'Alamofire', '~> 3.1.4'
pod 'SwiftyJSON', '~> 2.3.2'

just change it to

target "TargetName" do
    pod 'Alamofire', '~> 3.1.4'
    pod 'SwiftyJSON', '~> 2.3.2'
end

After the new changes to cocoapods, You have to add the following lines to your podfile.

target "YOUR_PROJECT_NAME" do

     pod "YOUR_POD"

end

From the CocoaPods website:

CocoaPods provides a pod init command to create a Podfile with smart defaults. You should use it.


you must add target 'your target' do and end around you pod like below.

target 'your target' do
pod 'AFNetworking', '2.6.3'
pod 'MBProgressHUD', '~> 0.9.1'
pod 'PDKeychainBindingsController', '~> 0.0.1'
end

plus: You may be need remove the pods dir, Podfile.lock and xcworkspace file, run the pod install again.


I got the same issue today. For mitigation, I unintall cocoapod, then install again version 0.39.

here is the link how to uninstall: https://superuser.com/questions/686317/how-to-fully-uninstall-the-cocoapods-from-the-mac-machine

This answer does not fix the root cause, but can get you unblocked. I don't have enough reputation to leave comments, so I put an answer here to unblock you.