Xcode "Manage Version and Build Number" option

IosXcodeApp StoreApp Store-Connect

Ios Problem Overview


I have just updated to Xcode 13 Beta and I am about to upload my first build to App Store using this version of Xcode. This version of Xcode shows a new App Store Connect distribution option which I previously haven't seen:

> Manage Version and Build Number
>
> This will change the version and build number of all content in your app to 1.2 (3).

enter image description here

I have already increased my version and build number from Xcode before archiving. What should we do here? If it is an automated way of build increment, what are the benefits of using it?

Ios Solutions


Solution 1 - Ios

> I have already increased my version and build number from Xcode before archiving. What should we do here?

If you are sure that you have already updated your version/build number before archiving, then you can uncheck this and this will be ignored.

> If it is an automated way of build increment, what are the benefits of using it?

  1. It provides you a chance to change version/build just in case you forgot about it. There was no indication for this in previous Xcode versions.

  2. It allows you to change version/build number before export/upload (after archiving), previously you had to create a new archive if you wanted to change the version/build number.

Solution 2 - Ios

For folks using fastlane and straggling with xcode changing build version.

New in Xcode 13:

> When uploading an app to App Store Connect, the distribution assistant > in Xcode detects whether your app has a valid build number > (CFBundleVersion). If your app has an invalid number (like one that > was used previously, or precedes your current build number), the > distribution assistant provides an option to automatically increment > it to a valid number. In addition, the distribution assistant ensures > that the build numbers of all embedded content in your app (such as > app extensions, App Clips, or watchOS apps) are in sync with your app. > Note that this doesn’t modify your source code or your archive; Xcode > updates the build number in a staged copy of your app before packaging > and uploading it to App Store Connect. (59826409)

When using fastlane for building and releasing apps, you can pass "manageAppVersionAndBuildNumbe: false" parameter to export_options of build_app action to disable xcode version change.

build_app( scheme: "your_app_scheme", export_options:{ manageAppVersionAndBuildNumber: false })

Solution 3 - Ios

i ran into something unexpected with this - it also changes version numbers of frameworks embedded into the app.

https://developer.apple.com/forums/thread/690647

Attributions

All content for this solution is sourced from the original question on Stackoverflow.

The content on this page is licensed under the Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license.

Content TypeOriginal AuthorOriginal Content on Stackoverflow
QuestionUmit KayaView Question on Stackoverflow
Solution 1 - IosTarun TyagiView Answer on Stackoverflow
Solution 2 - IossalabahaView Answer on Stackoverflow
Solution 3 - Iosmatt bezarkView Answer on Stackoverflow