错误:包中的Info.plist必须包含CFBundleIdentifier键

Cle*_*iro 6 iphone xcode continuous-integration continuous-deployment ios

我正在尝试使用altool提交我的iphone应用程序.但是,提示以下错误:

altool[18508:507] *** Error: (
    "Error Domain=ITunesConnectFoundationErrorDomain Code=-27000 \"The Info.plist in the package must contain the CFBundleIdentifier key.\" UserInfo=0x7f {NSLocalizedDescription=The Info.plist in the package must contain the CFBundleIdentifier key., NSLocalizedFailureReason=Unable to validate your application.}",
    "Error Domain=ITunesConnectFoundationErrorDomain Code=-27001 \"The Info.plist in the package must contain the CFBundleVersion key.\" UserInfo=0x7f {NSLocalizedDescription=The Info.plist in the package must contain the CFBundleVersion key., NSLocalizedFailureReason=Unable to validate your application.}",
    "Error Domain=ITunesConnectFoundationErrorDomain Code=-27002 \"The Info.plist in the package must contain the CFBundleShortVersionString key.\" UserInfo=0x7f {NSLocalizedDescription=The Info.plist in the package must contain the CFBundleShortVersionString key., NSLocalizedFailureReason=Unable to validate your application.}",
    "Error Domain=ITunesConnectFoundationErrorDomain Code=-27000 \"The package does not contain an Info.plist.\" UserInfo=0x7f{NSLocalizedDescription=The package does not contain an Info.plist., NSLocalizedFailureReason=Unable to validate your application.}"
Run Code Online (Sandbox Code Playgroud)

我已经验证了这样的键(CFBundleIdentifier,CFBundleVersion,CFBundleShortVersionString)在Info.plist中.另外,我从.ipa文件(使用xcodebuild和xcrun - 命令行生成)打开了Payload,并且可以确认这些密钥也在Info.plist文件中.

当我使用XCode进行编译,存档和提交时,验证通过.

有帮助吗?

我的Xcode版本:6.1.1(6A2008a)OSX 10.9.5

Ser*_*kov 6

我有一个与CI构建服务器类似的问题.

"Error Domain=ITunesConnectFoundationErrorDomain Code=-27000 \"Could not find a CFBundlePackageType within the Info.plist; or the package is missing an Info.plist.\" UserInfo=0x7fe72051f3a0 {NSLocalizedDescription=Could not find a CFBundlePackageType within the Info.plist; or the package is missing an Info.plist., NSLocalizedFailureReason=Unable to validate your application.}"
Run Code Online (Sandbox Code Playgroud)

当我*.ipa使用新exportOptionsPlist选项重新编写导出脚本时出现此问题.旧脚本运行正常altool.新的不.

旧脚本:

xcodebuild -exportArchive -exportFormat ipa -archivePath "MyApp.xcarchive" -exportPath "MyApp.ipa" -exportProvisioningProfile "appstore-provision"
Run Code Online (Sandbox Code Playgroud)

新脚本:

xcodebuild -exportArchive -exportOptionsPlist "tools/export-options.plist" -archivePath "MyApp.xcarchive" -exportPath "MyApp.ipa"
Run Code Online (Sandbox Code Playgroud)

问题是,xcodebuild现在创建MyApp.ipa/MyApp.ipa代替MyApp.ipa.

我刚修好-exportPath:

xcodebuild -exportArchive -exportOptionsPlist "tools/export-options.plist" -archivePath "MyApp.xcarchive" -exportPath "."
Run Code Online (Sandbox Code Playgroud)