Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Xcode scheme change display name

Tags:

xcode

ios

build

I have a custom Xcode build scheme that moves some files to toggle between dev and prod variables. Can I change the app display name in the dev scheme as well?

For example, if the app name is "MyApp", it currently shows up on the home screen as "MyApp". Can I configure my dev build scheme so that it shows up on the home screen as "MyApp Dev"? I tried setting TARGET_NAME="MyApp Dev" in a pre-action build script, but it doesn't seem to work.

Xcode 7, iOS 9

like image 207
FeifanZ Avatar asked Oct 18 '15 18:10

FeifanZ


People also ask

How do I change the display name in Xcode?

Build Settings> Change "Product Name" TARGETS> Select app> Change "Display Name" Project Navigator> Select project name> Double-click> Change "project name"> Rename> Mange Scheme> Change "Scheme name"

How do I change schema in Xcode?

Choose Product > Scheme > Edit Scheme. In the dialog that appears, click the Run option in the scheme editor's left pane. In the main pane, click Options. Specify the options you want.

How do I find my Xcode scheme name?

Step 1: Add the key "SchemeName" to your Info. plist with type string. Make sure and select a target from under "Provide build settings from". Step 3: Now duplicate that scheme as many times as you like (Manage Schemes...

How do I change my bundle name?

Change the Bundle IDChoose your project from the left side, then your app target under TARGETS, select the General tab and rename the Bundle Identifier.


1 Answers

You can do that easily.

  1. Add a "User-Defined Setting" (e.g. DISPLAY_NAME) to your target and set different values for different Schemes.
  2. Go to the "Info.plist" of your target and add "Bundle display name" key and set its value to "$(DISPLAY_NAME)"
like image 97
Semih Cihan Avatar answered Oct 11 '22 14:10

Semih Cihan