问题描述
我正在尝试运行建筑博览会,但由于CocoaPods过时而不断运行错误。
[!] `RNFBApp` requires CocoaPods version `>= 1.10.2`, which is not satisfied by your current version, `1.10.1`.
Error: Your project requires a newer version of CocoaPods, you can update it in the build profile in eas.json by either:
- changing the current version under key "cocoapods"
- switching to an image that supports that version under key "image"
我已尝试按照说明用我想要的版本更新我的EAS文件,但似乎被忽略了:/
{
"cli": {
"version": ">= 0.38.1"
},
"build": {
"development": {
"distribution": "internal",
"android": {
"gradleCommand": ":app:assembleDebug"
},
"ios": {
"buildConfiguration": "Debug",
"cocoapods": "1.11.2"
}
},
"preview": {
"distribution": "internal"
},
"production": {}
},
"submit": {
"production": {}
}
}
有人知道我如何解决这个问题吗?我的构建在本地运行得很好,并在模拟器上加载,不用担心。
推荐答案
既然我已经解决了这个问题,我将分享我的故事:
我在Windows上运行以下命令:
eas build --profile release --platform ios
以下是我的eas.json:
的相关部分 {
"build": {
"release": {
"android": {
"buildType": "app-bundle",
"gradleCommand": ":app:bundleRelease"
},
"ios": {
"cocoapods": "1.11.2"
}
}
}
}
将CocoaPods密钥添加到eas.json解决了我的问题。