I have three configurations in my iOS project:
Now I want to change the name of the App as follows:
Is there a way I can easily achieve this in Xcode with some type of "compiler-if-else-macro-thing"?
All you have to do is click on the blue project icon -on top of the left- and go to the “Build Settings” tab, search “Info. plist” and choose “Info. plist File” section. Then change the information of the section from your folder's name.
Press ⌘+⇧+o to get the Quick Open Dialog. Enter name of property list file e.g. " info. plist " and press "Enter" Open "Version Editor" -> Property List File is shown as source code.
The Info. plist file contains critical information about the configuration of an iOS mobile app—such as iOS versions that are supported and device compatibility—which the operating system uses to interact with the app. This file is automatically created when the mobile app is compiled.
You can see the XML version of the plist by opening the file in a text editor such as Sublime Text or Atom. *Edit - you can also right click the Info.
Changing display name of app for respective configurations: one way to achieve this is by using the same info plist file that you have.
Part 1: create an user defined variable
Part 2: use it
Then for appropriate configuration it will select name from BUNDLE_DISPLAY_NAME variable in build settings.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With