iPhone:在命令行(Mac OS X)中压缩.app文件会删除CodeSigning [英] iPhone: Compressing .app files in command line (Mac OS X) removes CodeSigning

查看:199
本文介绍了iPhone:在命令行(Mac OS X)中压缩.app文件会删除CodeSigning的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试使用TeamCity对我的iPhone应用程序进行简单的构建自动化,但遇到这个棘手的问题..

I am trying to do a simple build automation of my iPhone apps with TeamCity, but having this nagging issue..

当我手动拾取并安装.app文件时从构建文件夹它工作得很好(与iTunes顺利同步,我可以看到我的手机上的应用程序)

When I manually pickup and install .app file from the build folder it works great (syncs smoothly with iTunes and I can see the app on my phone)

但是当我尝试用/ bin / zip或者拉链时同上...然后压缩的内容松开了CodeSigning(iTunes说它无法安装这个应用程序,因为它没有签名)

But when I try to zip this with /bin/zip or ditto...then the zipped contents loose the CodeSigning (iTunes says that it cannot install this app because its not signed)

我尝试了不同的组合..

I have tried different combinations of these..

ditto -ck --rsrc --keepParent HelloWorld.app HelloWorld.zip

ditto -ck --rsrc --keepParent HelloWorld.app HelloWorld.zip

还有什么想法?

我也试过这个但是仍然得到同样的错误

I tried this too but still getting the same error

version=$(date "+%Y-%m-%d.%H.%M.%S")
cd "$CONFIGURATION_BUILD_DIR"
zip -r -y "HelloWorld-$version.zip" HelloWorld.app


推荐答案

你需要使用-y选项zip:

You need to use the -y option on zip:

zip -r -y zipped_blahapp.zip blahapp.app




-y

-y

在zip存档中存储符号链接,而不是压缩
并存储
引用的文件链接(仅限UNIX)。

Store symbolic links as such in the zip archive, instead of compressing and storing the file referred to by the link (UNIX only).

更新

现在Xcode存档功能可从命令行,你可能应该使用它:

Now the Xcode archive functionality is available from the command line, you should probably be using that:

xcodebuild archive -workspace $APPNAME.xcodeproj/project.xcworkspace -scheme $APPSCHEMENAME > $OUTDIR/logs/$APPNAME.log

这篇关于iPhone:在命令行(Mac OS X)中压缩.app文件会删除CodeSigning的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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