无法使用 Xcode 存档(错误 - PhaseScriptExecution 失败,退出代码非零),但构建成功 [英] Can't archive with Xcode (error - PhaseScriptExecution failed with a non zero exit code), but the build is successful

查看:17
本文介绍了无法使用 Xcode 存档(错误 - PhaseScriptExecution 失败,退出代码非零),但构建成功的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

很抱歉图片中出现黑色标记.

I am sorry for the black marks in the image.

我看到多篇帖子建议解决这个问题,Lock unlocks keychain(尝试过),pod Update(尝试过),clear build(尝试过),签名,在构建设置中跳过安装(尝试过) - 无其中确实有效.

I have seen multiple posts suggesting an answer to this problem, Lock unlocks keychain (tried it), pod Update (tried it), clear build(tried it), signing, skip install in build settings(tried it) - None of them actually worked.

我用 Expo 构建了我的 iOS 应用程序,然后我做了 expo 弹出来创建用于 Xcode 构建和归档的 iOS 文件夹,构建每次都成功,它甚至可以在模拟器和我的设备上运行(iPhone7)但它总是无法通过抛出此错误来存档 - 未分类 - 命令 PhaseScriptExecution 失败,退出代码非零..

I built my iOS app in react native with Expo, after which I did expo eject to create the iOS folder for Xcode build and archiving, the build is successful every time and it even runs on the simulator and in my device(iPhone 7) but it always failed to archive by throwing this error - Uncategorised - Command PhaseScriptExecution failed with a non zero exit code..

任何帮助指出我应该往哪个方向前进或我正在做的可能是什么错误都会有很大帮助.如果我应该提供有关此的更多详细信息,请告诉我.谢谢!

Any help to point me in which direction should I go or what can be the possible mistake that I am doing will be of great help. Do let me know if, I should provide any more detail about this. Thank you!

Xcode 版本 - 11.0Mac 版本 - 10.15 CatalinaiPhone 操作系统 - 13.1.3

Xcode Version - 11.0 Mac Version - 10.15 Catalina iPhone OS - 13.1.3

我尝试过的几个链接 -

Few links I tried from -

  1. "${PODS_ROOT}/SwiftLint/swiftlint"导致Command PhaseScriptExecution failed with a nonzero exit code";使用 Xcode 10
  2. https://github.com/apollographql/apollo-ios/issues/395
  3. https://www.reddit.com/r/iOSProgramming/comments/al9box/getting_an_error_command_phasescriptexecution/

推荐答案

根据之前的答案,以下对我有用:

Based on the previous answers, the following worked for me:

  1. 退出 XCode.
  2. 删除所有相关文件:PodfilePodfile.lokPods文件夹和.workspace文件.
  3. 重新创建 Podfile 并打开新的 .workspace 文件.
  1. Quit XCode.
  2. Delete all relevant files: Podfile, Podfile.lok, Pods folder and .workspace file.
  3. Recreate the Podfile and open the new .workspace file.

干杯

PS:就我而言,我在将现有项目(工作区)复制到新机器后遇到了这个问题.

PS: In my case, I hit this issue after copying an existing project (workspace) to a new machine.

这篇关于无法使用 Xcode 存档(错误 - PhaseScriptExecution 失败,退出代码非零),但构建成功的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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