Home > other >  Why does my Xcode archive version number differ from the build version number?
Why does my Xcode archive version number differ from the build version number?

Time:10-07

I've been working on this React-Native project for many years and with this latest version (305) the build number in the archive is showing as 5, not 305. I'm not sure what I changed. See the general tab setting here in the attached image. Why does this not match?

Image top half: info.plist Image bottom half: archive window

xcode example image

CodePudding user response:

The problem is that your version value is incorrect. You are to supply a version string, which is a string (not a number) of the form:

MAJOR.MINOR

or

MAJOR.MINOR.PATCH

These are not decimals. The major, minor, and patch values are all (string representations of) integers. Thus, for example, "1.34" is much bigger, not smaller, than "1.4" — because 34 is much bigger than 4.

If you were numbering these versions correct, you would never in a million years have gotten to a major version as big as 305.

When you submit a new version to TestFlight, you increment the other number, the Build, which is an integer. You typically increment the Version in some way only when you release a new version in the app store.

CodePudding user response:

I changed the version to 306 and made another archive and the number was correct. Changed it back to 305 and archived, and it was correct. I guess this was a simple glitch. enter image description here

  • Related