ios - Xcode project environment variables -
how distinguish multiple environments in ios app?
my swift app uses external api connection , have 2 api urls - testing , productive.
is there way how use 1 variable , set value testing in xcode , value appstore release?
currently using xcode 6.3.1 application deployment target ios 8.1
in swift need use "swift compiler - custom flags" instead of pre processor macro...
set flag shown in figure below
use below code checking..
var url; #if debugurl url = ** debug url ** #else url = ** release url ** #endif
note : add debug symbol -d debug entry.
Comments
Post a Comment