[ios] How to check version of a CocoaPods framework

I have updated Flurry via CocoaPods, but how can I check if Flurry was updated?

I mean the terminal shown me that everything is ok:

Installing FlurrySDK (4.2.3)
Generating Pods project
Integrating client project

but I am not sure that it has been updated.

This question is related to ios version cocoapods

The answer is


The Podfile.lock keeps track of the resolved versions of each Pod installed. If you want to double check that FlurrySDK is using 4.2.3, check that file.

Note: You should not edit this file. It is auto-generated when you run pod install or pod update


The highest voted answer (MishieMoo) is correct but it doesn't explain how to open Podfile.lock. Everytime I tried I kept getting:

enter image description here

You open it in terminal by going to the folder it's in and running:

vim Podfile.lock

I got the answer from here: how to open Podfile.lock

You close it by pressing the colon and typing quit or by pressing the colon and the letter q then enter

:quit // then return key
:q // then return key

Another way is in terminal, you can also cd to the folder that your Xcode project is in and enter

$ open Podfile.lock -a Xcode

Doing it the second way, after it opens just press the red X button in the upper left hand corner to close.


You can figure out version of Cocoapods by using below command :

pod —-version

o/p : 1.2.1

Now if you want detailed version of Gems and Cocoapods then use below command :

gem which cocoapods (without sudo)

o/p : /Library/Ruby/Gems/2.0.0/gems/cocoapods-1.2.1/lib/cocoapods.rb

sudo gem which cocoapods (with sudo)

o/p : /Library/Ruby/Gems/2.0.0/gems/cocoapods-1.2.1/lib/cocoapods.rb

Screenshot 1

Now if you want to get specific version of Pod present in Podfile then simply use command pod install in terminal. This will show list of pod being used in project along with version.

Screenshot 2


[CocoaPods]

Cocoapods version

CocoaPods program that is built with Ruby and it will be installable with the default Ruby available on macOS.

pod --version //1.8.0.beta.2
//or
gem which cocoapods //Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.0.beta.2/lib/cocoapods.rb

//install or update
sudo gem install cocoapods

A pod version

Version of pods that is specified in Podfile

Podfile.lock

It is located in the same folder as Podfile. Here you can find a version of a pod which is used

Search for pods

If you are interested in all available version of specific pod you can use

pod search <pod_name>
//or
pod trunk info <pod_name>

Set a pod version in Podfile

//specific version
pod '<framework_name>', "<semantic_versioning>"
// for example
pod 'MyFramework', "1.0"

pod --version used this to check the version of the last installed pod


I wrote a small commandline tool that parses the Podfile.lock and shows which version of each Pod is currently installed. It will also check for the latest version online and give you a summary of dependencies which are out-of-date.

You can find it on Github: https://github.com/citruz/podchecker


pod outdated

When you run pod outdated, CocoaPods will list all pods that have newer versions that the ones listed in the Podfile.lock (the versions currently installed for each pod) and that could be updated (as long as it matches the restrictions like pod 'MyPod', '~>x.y' set in your Podfile)


Podfile.lock file right under Podfile within your project.

The main thing is , Force it to open through your favourite TextEditor, like Sublime or TextEdit [Open With -> Select Sublime] as it doesn't give an option straight away to open.


To check version of cocoapods from terminal:

For Sudoless:

gem which cocoapods

For Sudo:

sudo gem which cocoapods

Also note: If you want to edit podfile or podfile.lock don't edit it in editors. Open only with XCode.


pod --version

to get the version of installed pod


Examples related to ios

Adding a UISegmentedControl to UITableView Crop image to specified size and picture location Undefined Symbols error when integrating Apptentive iOS SDK via Cocoapods Keep placeholder text in UITextField on input in IOS Accessing AppDelegate from framework? Autoresize View When SubViews are Added Warp \ bend effect on a UIView? Speech input for visually impaired users without the need to tap the screen make UITableViewCell selectable only while editing Xcode 12, building for iOS Simulator, but linking in object file built for iOS, for architecture arm64

Examples related to version

Which TensorFlow and CUDA version combinations are compatible? How can the default node version be set using NVM? Node - was compiled against a different Node.js version using NODE_MODULE_VERSION 51 Which ChromeDriver version is compatible with which Chrome Browser version? How to find which version of TensorFlow is installed in my system? How to update Ruby Version 2.0.0 to the latest version in Mac OSX Yosemite? What does 'Unsupported major.minor version 52.0' mean, and how do I fix it? Find nginx version? How to check all versions of python installed on osx and centos How can I specify the required Node.js version in package.json?

Examples related to cocoapods

Undefined Symbols error when integrating Apptentive iOS SDK via Cocoapods The iOS Simulator deployment targets is set to 7.0, but the range of supported deployment target version for this platform is 8.0 to 12.1 Xcode 10.2.1 Command PhaseScriptExecution failed with a nonzero exit code Updating to latest version of CocoaPods? 'Linker command failed with exit code 1' when using Google Analytics via CocoaPods ld: framework not found Pods How to update a single pod without touching other dependencies Error "library not found for" after putting application in AdMob cocoapods - 'pod install' takes forever Xcode - ld: library not found for -lPods