I would like to export an ipa for appstore and an adhoc in one build

I used “xcode archive and export” to build a adhoc build then I used “Export iOS and tvOS Xcode archive” to export another IPA from xarchive for appstore. Everything seems ok but at the end there is only one ipa generated (the appstore one ). How can I have two separated IPA ? There doesn’t seem to be a way to select another output for the export ios and tvos xcode archive step.

1 Like

Hi @ecaradec-nsb,

You’re right, and the solution is really simple: use a second Xcode Archive step, or alternatively, a probably more efficient solution is to use the Export iOS and tvOS Xcode archive step after the first Xcode Archive step.

Multiple Xcode Archive steps is also fine, but the first Xcode Archive step will generate the required .xcarchive xcode archive, so if all you want to do is to do another export using the same archive you can use the Export iOS and tvOS Xcode archive step for that.

If you’d need to change some configs for the second IPA (e.g. use different API keys) then the best solution is to use a second Xcode Archive step, as exporting from the same .xcarchive will result in the exact same app (IPA) just signed differently.

If you have any questions just let us know! :slight_smile:

I don’t think this can resolve the issue because the additional Export iOS and tvOS Xcode archive would override the .ipa file that generated from Xcode Archive step. I didn’t find a way to generate a different file…
is that a way to actually export two different .ipa(same build but different export method) in one workflow and one Xcode archive step?

thanks!

Not a problem.

E.g. a step sequence like:

  • Archive 1
  • Deploy 1
  • Archive 2
  • Deploy 2

works. There’s no reason why you could not add more than one Archive or Deploy steps :slight_smile:

It’s also possible to alias the outputs: Monthly release of Bitrise CLI tools and summary of updates (May, 2017) - CLI v1.6.1 (2. Step Output Aliases)

Yes. This’s how I make it work yesterday.
I was assumed deploy would gather all files to upload and just need to do it once. I was wrong.
thank you for your reply!

1 Like

Depends on your setup. In general, if you use our Deploy to Bitrise.io step that can indeed deploy multiple IPAs / APKs if the file names are different. E.g. if you store appAdHock.ipa and appAppStore.ipa in the $BITRISE_DEPLOY_DIR then the Deploy to Bitrise.io step will attach both to the build.

But you can of course use multiple steps as well, in general both are perfectly fine solutions, which one is better depends on your preference really :slight_smile:

How do I specify what the .ipa file is named during the “Xcode Archive & Export” and “Export iOS and tvOS Xcode archive” steps? I would like to setup two “Export iOS and tvOS Xcode archive” steps that creates two different .ipa file names that are uploaded via the “Deploy to Bitrise.io” step. However, I do not see where to specify the name of the exported ipa file within the “Export iOS and tvOS Xcode archive” nor the “Xcode Archive & Export” steps. Any ideas?

Hi @mikeberlin-vin!

This is not something that you’ll be able to modify on Bitrise so easily. For reference please check out these discussions.