OGeek|极客世界-中国程序员成长平台

标题: ios - ionic 运行无法部署到设备 [打印本页]

作者: 菜鸟教程小白    时间: 2022-12-13 12:13
标题: ios - ionic 运行无法部署到设备

我使用的是 Mac OS X 10.11。我正在尝试通过运行 sudo ionic run ios --device 将构建部署到设备(iPhone 4),我收到以下错误消息:

Check dependencies
Code Sign error: No code signing identities found: No valid signing identities (i.e. certificate and private key pair) were found.

** BUILD FAILED **


The following build commands failed:
    Check dependencies
(1 failure)
Error code 65 for command: xcodebuild with args: -xcconfig,/Users/john/Desktop/Myproject/platforms/ios/cordova/build-debug.xcconfig,-project,Myproject.xcodeproj,ARCHS=armv7 armv7s arm64,-target,Myproject,-configuration,Debug,-sdk,iphoneos,build,VALID_ARCHS=armv7 armv7s arm64,CONFIGURATION_BUILD_DIR=/Users/john/Desktop/Myproject/platforms/ios/build/device,SHARED_PRECOMPS_DIR=/Users/john/Desktop/Myproject/platforms/ios/build/sharedpch
ERROR running one or more of the platforms: Error: /Users/john/Desktop/Myproject/platforms/ios/cordova/run: Command failed with exit code 2

You may not have the required environment or OS to run this project

只运行 ionic run ios 时我没有问题,这会将应用程序部署到模拟器中。我该如何克服这个问题?



Best Answer-推荐答案


另一种方法是

转到您项目的平台目录/platforms/ios

在控制台中写入 open . 这将使用 Finder 打开您的文件夹。

之后,使用 XCode 打开 YourProject.xcodeproj 并选择您的设备并点击运行。

祝你好运

关于ios - ionic 运行无法部署到设备,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/34197529/






欢迎光临 OGeek|极客世界-中国程序员成长平台 (http://jike.in/) Powered by Discuz! X3.4