Cocoapods默认安装旧版Stripe库

时间:2014-11-09 21:22:59

标签: ios objective-c swift cocoapods stripe-payments

目前正尝试使用以下指南在Swift中的全新iOS应用中设置Stripe:https://stripe.com/docs/mobile/ios。马上就遇到了Cocoapods的麻烦。回购可以在这里找到:https://github.com/ktransier/stripeTest/blob/master/Podfile

首先尝试使用该行:

pod 'Stripe'

这导致:

Analyzing dependencies
Downloading dependencies
Installing PaymentKit (1.0.2)
Installing Stripe (1.0.2)
Generating Pods project
Integrating client project

我需要2.2.1版(最新版本),但它正在安装1.0.2。

接下来,我尝试使用显式版本号,从Cocoapods站点复制:

pod 'Stripe', '~> 2.2'

终端输出:

[!] Unable to satisfy the following requirements:
- `Stripe (~> 2.2)` required by `Podfile`

这是我的堆栈:

CocoaPods : 0.34.4
Ruby : ruby 1.9.3p448 (2013-06-27 revision 41675) [x86_64-darwin12.4.1]
RubyGems : 2.4.1
Host : Mac OS X 10.10 (14A389)
Xcode : 6.1 (6A1052d)
Git : git version 1.9.3 (Apple Git-50)

如何安装最新的Stripe库?

1 个答案:

答案 0 :(得分:2)

看起来您的规格报告的本地副本暂时没有更新。尝试运行

pod repo update