如何找到安装的可可豆荚的版本?

如何找到安装的可可豆荚的版本?

我问的不是可可豆荚的 宝石版本,而是可可豆荚本身的版本。理想情况下,它会说“ pod GreatViewController 安装在1.2.3版本中,新版本可用: 1.2.6”。

有这种事吗?

84886 次浏览

EDIT

Based on your clarification you're looking for pod outdated. You can see more information about this with pod outdated --help

Original answer before question was edited

The command you want is pod --version

In the future you should use pod --help to find answers such as this. You can also use pod COMMAND --help to get help for specific commands.

To get the version of cocoa pods

pod --version

To get the version of your pod, look in the Podfile.lock

When you install or update the pod, you can see the versions of both.

You will find the version # in your Podfile.lock of all the pods you are currently using in your project. You will find this file at the same location as your Podfile.

This is how mine looks like:

PODS:
- Alamofire (3.4.1)
- EPSignature (1.0.2)
- Kingfisher (2.4.2)
- MBProgressHUD (0.9.2)
- SwiftyJSON (2.3.2)


DEPENDENCIES:
- Alamofire (~> 3.4)
- EPSignature
- Kingfisher
- MBProgressHUD (~> 0.9.1)
- SwiftyJSON


SPEC CHECKSUMS:
Alamofire: 01a82e2f6c0f860ade35534c8dd88be61bdef40c
EPSignature: 1f925f20b837046de46b4d396bc6e432ea383908
Kingfisher: 05bf8d04408aaa70fcd2c8c81b9f1d0f1ad313dd
MBProgressHUD: 1569cf7ace17a8bac47aabfbb8580a49690386d1
SwiftyJSON: 04ccea08915aa0109039157c7974cf0298da292a


PODFILE CHECKSUM: 95eb36b090480f40d91543881d6ddb76bb1b8ca8


COCOAPODS: 1.0.1
pod search pod_name

example

pod search Alamofire

So you should have the pod name to use this command and it will give you a response like the following in the command line

-> Alamofire (4.7.3) Elegant HTTP Networking in Swift pod 'Alamofire', '~> 4.7.3' - Homepage: https://github.com/Alamofire/Alamofire - Source: https://github.com/Alamofire/Alamofire.git - Versions: 4.7.3, 4.7.2, 4.7.1, 4.7.0, 4.6.0, 4.5.1, 4.5.0, 4.4.0, 4.3.0, 4.2.0, 4.1.0, 4.0.1, 4.0.0, 3.5.1, 3.5.0, 3.4.2, 3.4.1, 3.4.0, 3.3.1, 3.3.0, 3.2.1, 3.2.0, 3.1.5, 3.1.4, 3.1.3, 3.1.2, 3.1.1, 3.1.0, 3.0.1, 3.0.0, 3.0.0-beta.3, 3.0.0-beta.2, 3.0.0-beta.1, 2.0.2, 2.0.1, 2.0.0, 2.0.0-beta.4, 2.0.0-beta.3, 2.0.0-beta.2, 2.0.0-beta.1, 1.3.1, 1.3.0, 1.2.3, 1.2.2, 1.2.1, 1.2.0, 1.1.5, 1.1.4, 1.1.3 [master repo]

Open Terminal.

Change directory to your project and type the following command to open the Podfile.lock file.

$ open Podfile.lock -a Xcode

if You are finding the version of a particular pod installed, then follow below steps:

  1. Open Xcode
  2. Click on "Project Navigator"
  3. Click on "Pods"
  4. Open The Pod you wanna know the version of
  5. Expand it
  6. Expand the "Supporting Files" folder
  7. Click On yourpodname.plist
  8. Read the Bundle Version string, short