Ad Hoc App Packager script for iPhone apps
If you're beta testing your iPhone apps, you will no doubt be familiar with Ad Hoc builds. These are the builds you send out to your testers along with a mobile provisioning profile that lets them test your app out on their iPhones and iPod Touches.
This involves doing a few repetitive things that I just wrote a script to automate.
Specifically, the Ad Hoc App Packager script automatically:
- Creates an IPA file that users can launch to add your App to iTunes
- Uses the iTunesArtwork file in the IPA so that your app has an icon in iTunes
- Copies the correct mobile provisioning profile into the package folder for you so you can send this to your beta testers.
- Checks that you've updated the version of your app and doesn't let you package it if you haven't
- Backs up your dSYM file so that you can decipher crash reports sent from your beta testers
It was the last point that initially led me down the road to write this script: they don't tell you anywhere that you need to keep those dSYM files if you want to troubleshoot crash builds (the web's littered with people who find out at the worst possible time; when they actually need to do it and have long since overwritten the dSYM files).
- Copy the adhoc folder into your Xcode project's folder
- Look in the adhoc/packages/<AppVersion> folder to find your IPA and .mobileprovision file. Send those to your beta testers.
I hope this little script makes your life easier (and if it does, I'll gladly let you fuel my App Store addiction by leaving me a tip.)
Update: I've merged bug fixes and non-zero exit codes for error conditions thanks to Rasheed Abdul-Aziz (thanks, man + GitHub fork queues rock!) I've also added a
-s) option. If you use it, there will be no output on stdout unless there is an error (good for continuous integration systems or for using as part of a greater automated build process, etc.)