Starting with Xcode v6.0, Apple has changed the process of creating ipa files.
Earlier, it was possible to create an adhoc/distribution ipa using the provisioning profile & certificate. However, now it is mandatory to provide the developer account information, which your clients might not be willing to share.

It is still possible to create an ipa manually, using the terminal & xcodebuild command.

1. Assign the required certificates & provisioning profile in the Build Settings of your project.

2

 

2. Remember the Provisioning Profile name. You will be using it later.

3. Create the build using the Archive menu option.

4. In the organizer, select your build, Right-Click, ‘Show In Finder’ & copy the xcarchive file to a location of your choice.

1

5. Now, we are ready to create the ipa. xcodebuild has a flag -exportArchive which can create an ipa file using the xcarchive we obtained in step 4.

6. Following is the code for a shell script which takes 3 parameters & creates an ipa:

7. Create a new shell script on your mac & copy paste the code quoted above.

Usage: ./script.sh <Path to xcarchive file> <Path of ipa file to be generated> <Name of the provisioning profile(enclosed in double quotes “”)>

Example: ./script.sh ./MyArchive.xcarchive ./My.ipa “Assault Vector Dev”

8. Done 🙂

 

Xcode howto: Exporting ipa using xcodebuild
Tagged on:         

One thought on “Xcode howto: Exporting ipa using xcodebuild

  • August 22, 2015 at 7:46 pm
    Permalink

    i started prainommgrg when I was 11. I have always really enjoyed it! =D I just looked more towards the web side of things. I have picked up many books on Objective-C and I recently began seriously looking towards iPhone Development. After watching your tutorials, reading a lot of Apple’s Documentation and prainommgrg books (over long a time), I now have a good standing with Objective-C and am very glad to know a brand new language! Thanks for encouraging me with Obj-C!

Comments are closed.