views:

199

answers:

1

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

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)

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

Any more ideas?

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
+1  A: 

You need to use the -y option on zip:

zip -r -y zipped_blahapp.zip blahapp.app

-y

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

Cannonade
Thank you for the prompt response but still getting the same issue, I have edited my question with the exact script I am using..
Santthosh
@Santthosh Sorry you are still having the issue. I had exactly the same problem and adding -y resolved it for me. You script looks good to me. I'll update if I find any more info on this problem.
Cannonade
Sorry you were right...I was zipping before the CodeSign was happening (listed in another thread http://stackoverflow.com/questions/1409981/how-to-run-a-script-after-xcode-runs-codesign-on-my-iphone-app)
Santthosh
It works great! +1 for the -y :)
Santthosh
@Santthos Awesome ... glad you got it sorted :)
Cannonade