I registered my Dev and Prod schemes as different apps in Firebase. I want them to be separate, Each has unique bundle ID. I am using #if dev to identify if it is dev or pro
use
var firebasePlist: String? = Bundle.main.path(forResource: "GoogleService-Info", ofType: "plist")
if development == true{
firebasePlist = Bundle.main.path(forResource: "GoogleService-Info-DEV", ofType: "plist")
}
var options = FIROptions(contentsOfFile: firebasePlist)
FIRApp.configure(with: options)
but you'll have to have a variable called development with the value of true when you want to use the DEV GoogleService plist and the value of false is you want to use the regular GoogleService plist
Just use [FIRApp configureWithOptions:]
NSString *firebasePlist = [[NSBundle mainBundle] pathForResource:@"GoogleService-Info" ofType:@"plist"];
#if STAGING
firebasePlist = [[NSBundle mainBundle] pathForResource:@"GoogleService-Info-DEV" ofType:@"plist"];
#endif
FIROptions *options = [[FIROptions alloc] initWithContentsOfFile:firebasePlist];
[FIRApp configureWithOptions:options];