Is it possible to install multiple versions of cocoa pods on the same machine ? I need one project to be build from cocoa pod 0.33 and another one from the latest version. Is this possible ?
Make sure your imagePullPolicy is set to Always(this is the default). That means when a pod is deleted, a new pod will ensure it has the current version of the image. Then refresh all your pods. The simplest way to refresh all your pods is to just delete them and they will be recreated with the latest image.
<Specifying pod versions Later on in the project you may want to freeze to a specific version of a Pod, in which case you can specify that version number. Besides no version, or a specific one, it is also possible to use logical operators: '> 0.1' Any version higher than 0.1. '>= 0.1' Version 0.1 and any higher version.
Just rm -rf that pod's folder, and remove the line from the Podfile. Then run pod install again.
$ pod update 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).
I've made a small list of commands to use multiple versions of cocoapods, all tested with osx sierra 12.1, xCode 8
View all installed versions of cocoapods :
gem list --local | grep cocoapods
Install a specific version of cocoapods with gem
gem install cocoapods -v 0.33.0
Install pods with specific version of cocoapods (change to your wanted version):
pod _0.33.0_ install
All versions of Cocoapods can be found HERE
When you install new version of cocoapods, the old one is not removed unless you explicitly remove it with
gem uninstall cocoapods
and select the version to be removed.
You can use the old versions by giving version number in the command, surrounded by underscores, like this:
pod _0.38.2_ install
Since November 11, 2016 the master repo is not compatible with the old version and unless you have updated your Podfile correctly (replaced source "https://github.com/CocoaPods/Specs.git"
with source "https://github.com/CocoaPods/Old-Specs"
or just added the latter one) you will see an error when using 0.x version of cocoapods:
"[!] The master repo requires CocoaPods 1.0.0 - (currently using 0.38.2)"
Information on how and why is here.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With