0

My application support 20 languages such as: English, German, French, Danish ... Now I want to build 2 version: 1. English only 2. Full 20 languages.

Must I have to create 2 separate projects in order to build 2 IPA file?

I am using Xcode Version 6.4 (6E35b)

Nam Vu
  • 5,669
  • 7
  • 58
  • 90

1 Answers1

1

Duplicate your target then add a key (YOUR_KEY=1) in Target > Build Settings > Preprocessor Macros.

enter image description here

Now you can use #if #else #endif to define url for 2 targets.

#if English
#define kUrl @"https://english.example.com"
#else
#define kUrl @"https://world.example.com"
#endif
PowHu
  • 2,159
  • 16
  • 17