从 xcode 命令行生成 ipa
从命令行生成 IPA 文件的最佳方法是什么?
我使用 xcode 4.2 并使用以下方式生成存档:
xcodebuild -scheme AppStore clean archive
这会在协同设计后在构建输出目录中生成 .dSYM 和 .app 文件。我应该如何继续生成 .ipa 文件?换句话说,我正在寻找相当于在 GUI
- Organizer 中执行以下操作的命令行 - Archives
- Share
- iOS App Store Package
- Don't Re-sign
谢谢!
Whats the best approach for generating an IPA file from command-line?
I'm on xcode 4.2 and generating the archive using:
xcodebuild -scheme AppStore clean archive
This generates the .dSYM and .app files in the build output directory, after codesigning. How should I proceed to generate the .ipa file? In other words, I'm looking for the command-line equivalent of doing the following in GUI
- Organizer - Archives
- Share
- iOS App Store Package
- Don't Re-sign
Thanks!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
缺少的部分是使用 PackageApplication 实用程序。
/usr/bin/xcrun -sdk iphoneos PackageApplication -v $FULL_PATH_TO_APP -o $OUTPUT_PATH
您还可以传递此脚本选项以进行辞职和配置文件嵌入。分别使用
--sign
和--embed
标志。The missing piece is using the PackageApplication utility.
/usr/bin/xcrun -sdk iphoneos PackageApplication -v $FULL_PATH_TO_APP -o $OUTPUT_PATH
You can also pass this script options for resigning, and profile embedding. Using the
--sign
and--embed
flags respectively.这个工具使得构建(和分发)变得很简单:https://github.com/nomad/shenzhen
This tool makes it trivial to build (and distribute): https://github.com/nomad/shenzhen
存档后,您需要“导出”到所需的格式,即 ipa:
xcodebuild -sdk iphoneos7.0 -archivePath "path to archive file" -exportPath "path_for_export" -exportFormat ipa -exportArchive -exportProvisioningProfile "provisioning_profile_to_export_with"
After Archive, you need to "Export" to desired format ie ipa:
xcodebuild -sdk iphoneos7.0 -archivePath "path to archive file" -exportPath "path_for_export" -exportFormat ipa -exportArchive -exportProvisioningProfile "provisioning_profile_to_export_with"