The version of CocoaPods used to generate the lockfile

简介: The version of CocoaPods used to generate the lockfile

The version of CocoaPods used to generate the lockfile (1.12.1) is higher than the version of the current executable (1.11.3). Incompatibility issues may arise.

在我们使用cocoapods加载第三方库时,有时会碰到报这个错,这很明显是告诉我们现在所使用的cocoapods版本低于第三方库所要求的。


我们可以在终端中执行pod repo update 命令


如果执行pod repo update 命令报下面的错

Failed to connect to GitHub to update the CocoaPods/Specs specs repo - Please check if you are offline, or that GitHub is down


再执行pod update --verbose --no-repo-update

然后再执行pod repo update

根据提示再更新sudo gem install cocoapods

若还报错,有可能个gem版本问题,采用下面操作。这种操作很彻底,但是很复杂,能解决所有问题,会遇到系统的ruby权限问题,后面会有文章专门解决。不过万不得已不要走下面的流程。

升级cocoapods需要一个正确的操作流程和命令语句。


1、更新gem:sudo gem update --system

2、删除gem源:gem sources --remove https://ruby.taobao.org/

3、修改gem源:gem sources -a https://gems.ruby-china.org

4、查看gem源是否是最新的:gem sources -l

5、升级cocoapods:sudo gem install -n /usr/local/bin cocoapods --pre

6、查看升级后的cocoapods版本:pod --version


目录
相关文章
|
9月前
|
缓存 Java Maven
Idea Maven错误:was cached in the local repository, resolution will not be reattempted until the update
Idea Maven错误:was cached in the local repository, resolution will not be reattempted until the update
544 0
|
Java Maven
Maven报错 Error running ‘ [install]‘:No valid Maven installation found.maven不能用
Maven报错 Error running ‘ [install]‘:No valid Maven installation found.maven不能用
655 0
Plugin ‘maven-clean-plugin:3.1.0‘ not found
Plugin ‘maven-clean-plugin:3.1.0‘ not found
179 0
|
Java Maven
maven install时报错The packaging for this project did not assign a file to the build artifact
maven install时报错The packaging for this project did not assign a file to the build artifact
5721 0
Plugin [id: ‘com.github.kt3k.coveralls‘, version: ‘2.8.2‘] was not found in any of the following sou
Plugin [id: ‘com.github.kt3k.coveralls‘, version: ‘2.8.2‘] was not found in any of the following sou
116 0
成功解决 安装pywin32时出现python version 3.6-32 required, which was not found in the registry
成功解决 安装pywin32时出现python version 3.6-32 required, which was not found in the registry
成功解决 安装pywin32时出现python version 3.6-32 required, which was not found in the registry
|
Java Maven Android开发
how does eclipse know what tasks it should do when we select Maven build
how does eclipse know what tasks it should do when we select Maven build
how does eclipse know what tasks it should do when we select Maven build
成功解决​​​​​​​安装pywin32时出现python version 3.6 required, which was not found in the registry(二)
成功解决​​​​​​​安装pywin32时出现python version 3.6 required, which was not found in the registry
成功解决​​​​​​​安装pywin32时出现python version 3.6 required, which was not found in the registry(二)
成功解决​​​​​​​安装pywin32时出现python version 3.6 required, which was not found in the registry(一)
成功解决​​​​​​​安装pywin32时出现python version 3.6 required, which was not found in the registry
成功解决​​​​​​​安装pywin32时出现python version 3.6 required, which was not found in the registry(一)
成功解决You are using pip version 9.0.3, however version 10.0.1 is available. You should consider upgr
成功解决You are using pip version 9.0.3, however version 10.0.1 is available. You should consider upgr
成功解决You are using pip version 9.0.3, however version 10.0.1 is available. You should consider upgr