Problem statement:- I am using third party library, which need to have config.plist(name must be same), Config.plist have several key-value pairs, for production,Dev and stating environment, values for key does change. Right now i need to manually change file Name, like if i need to run app in production environment, i do change file name ConfigPROD.plist into Config.plist, for Staging i do change file name from ConfigDev.plist into Config.plist.
Need Solution like:- can i change, file content using preprocessor macro, like
#if isProductionBuild == 1
#define kBaseURL @"https://api.base.com/bart/"
#define kEnvironmnet @"PROD"
***//copy ConfigPROD.plist file content into Config.plist***
#elif isStageBuild == 1
#define kBaseURL @"https://api-stage.base.com/bart/"
#define kEnvironmnet @"stg"
*//copy ConfigSTG.plist file content into Config.plist*
#else
#define kBaseURL @"https://api-dev.base.com/bart/"
#define kEnvironmnet @"dev"
*//copy ConfigDEV.plist file content into Config.plist*
#endif
pleae see if we do have feature like "copy ConfigDEV.plist file content into Config.plist"
Note:- This file copy operation should get completed before third party library start using Config.plist.
