Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Using same version number for multiple Xcode targets Info.plist

I have a single Xcode project with multiple targets.

Each target has its own Info.plist file with the version number of that application. (CFBundleVersion and CFBundleShortVersionString)

How can I use single, common Version Number and Build Number source for each target, rather than editing each target's plist file?

like image 643
Mike Flynn Avatar asked Jan 08 '14 15:01

Mike Flynn


1 Answers

The following works with Xcode 12 and does not require User-Defined variables.

  1. Select your project
  2. Select Build Settings and find "Versioning"
  3. Set "Marketing Version" to be your version
  4. Set "Current Project Version" to be your build

Update project


  1. Next, select each of your targets
  2. Delete/remove any version number and it will use the default "Marketing Version"
  3. Delete/remove any build number and it will use the default "Current Project Version"
  4. Do this for all of your targets

Update targets


Once you do this, you only need to update the "Marketing Version" and "Current Project Version" for the Project and all of your targets will be updated accordingly.

like image 112
nurider Avatar answered Oct 27 '22 08:10

nurider