运行Pod安装时出错 [英] Error when running pod install

查看:84
本文介绍了运行Pod安装时出错的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我运行 pod install 命令时,出现以下错误:

When I run the pod install command, I am getting the following error:

[!] The `master` repo requires CocoaPods 1.0.0 -  (currently using 0.39.0)
Update Cocoapods, or checkout the appropriate tag in the repo.

更新目前不适合我。

我看着此问题的答案,但没有一个

如何继续使用CocoaPods 0.39.0进行依赖管理?

How can I continue to use CocoaPods 0.39.0 for my dependency management?

推荐答案

Cocoapods早在3月就存在速率限制问题,并实施了分片以避免将来出现此问题。 此处关于此事。

Cocoapods had an issue with rate limiting back in March and implemented sharding to avoid this problem in the future. There's a blog post here about it.

要解决此问题,您可以更新到Cocoapods的1.x版本,也可以将新的源添加到Podfile的顶部:

To fix this, you can either update to a 1.x version of Cocoapods or add the new source to the top of your Podfile:

source "https://github.com/CocoaPods/Old-Specs"

您可能需要替换另一条源代码行。

You probably will need to replace the other source line.

如果继续遇到问题,可能是因为特定的广告连播确实您正在使用的源中没有可访问的规范。我遇到了 Apptentive SDK 的问题。您可以像这样在Podfile中指定单个库的源:

If you continue having issues, it's likely because a specific pod does not have a spec accessible in the source you're now using. I ran into this issue with the Apptentive SDK. You can specify the source for an individual library in your Podfile likeso:

pod 'apptentive-ios', :git => 'https://github.com/apptentive/apptentive-ios.git', :tag => 'v3.0.0'

只需更新:git :tag 并带有正确的值。

Simply update :git and :tag with the correct values.

对于Github项目,最简单的方法是发布页面,无论您要查找哪个库以查找特定版本所需的标签。

For a Github project, it may be easiest to go through the Releases page of whatever library you're looking at to find the tag you want for a specific version.

这篇关于运行Pod安装时出错的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆