Heads up... You're reading this book for free, with parts of this chapter shown beyond this point astext.
You can unlock the rest of this book, and our entire catalogue of books and videos, with a raywenderlich.com Professional subscription.
Unlike other types of internal distribution, there’s no special “TestFlight build” separate from a finalized App Store build. TestFlight requires a distribution build. This Appendix walks you through creating a distribution build and uploading it to App Store Connect.
Before moving on, make sure you have the following set up already:
- An Apple ID enrolled in Apple’s developer program. You also need to be logged into Xcode with the same Apple ID.
- An App ID registered in Apple’s developer portal for the raywenderlich.com app.
- A distribution certificate registered in the developer portal and saved to Keychain Access on your Mac.
- An App Store distribution provisioning profile registered in the developer portal and registered with Xcode.
- An iOS device running iOS 13.4 or newer to match the sample app’s deployment target.
Open the starter folder for Chapter 6 and double-click Emitron.xcodeproj in the starter folder to open the project in Xcode.
Open the Signing & Capabilities tab for the emitron target. Scroll down to Signing (Release) and change Bundle Identifier to the one you registered in the developer portal back in Chapter 3, “Submitting Your First App for Review”.
Bundle identifiers are unique across Apple’s platforms, so your bundle identifier will be different in your case.
Next, open the Build Settings. Scroll down to the Signing section. For the following three build settings, click the disclosure icon (it looks like a “>”) and modify the build setting for the Release build configuration:
- Change Code Signing Identity to Apple Distribution.
- Change Development Team to the team you’re logged into.
- Change Provisioning Profile to Emitron Distribution Provisioning Profile or the name of your distribution provisioning profile if it’s different.
Your build settings should look like those in the next screenshot. Remember that your team name will be different from the one below.
Time to create the build. In Xcode, choose Any iOS Device (arm64) as the build destination. Select Product ▸ Archive from the menu to start the build process.
Organizer appears once Xcode finishes building. The top entry is the archive you just finished building.
Click Distribute. On the next screen, select App Store Connect as the distribution method. TestFlight’s backend systems all live in App Store Connect. That’s why you don’t see a special TestFlight option on this screen. Click Next.
Select Upload to send the build to App Store Connect. Click Next.
Leave the checkboxes for bitcode and symbols selected. Click Next.
On the following screen leave the default distribution certificate selected. Next to raywenderlich.app, click the dropdown and select Emitron Distribution Provisioning Profile. Click Next.
The next screen is a summary screen. Click Upload. Finally you see a confirmation screen saying that the upload completed successfully.