I wrote a build copy script for Xcode, but I was n...
# multiplatform
c
I wrote a build copy script for Xcode, but I was not able to find any credible info on this
🧵 1
f
Yes, that’s the one!
💯 1
Add a build script in shell to copy the file to the good place depending of the xcode build scheme/target
c
Actually I needed resources for Android side, how to configure so my build uses correct google-services.json for the selected build variant. Any leads on this?
f
try with dynamic value instead of file to init your firebase configuration
c
🤔 Dynamic values
Copy code
FirebaseOptions.Builder builder = new FirebaseOptions.Builder()
        .setApplicationId("YOUR_APP_ID") // e.g., "1:1234567890:android:abcdefg"
        .setApiKey("YOUR_API_KEY") // Your Web API Key from Firebase Console
        .setGcmSenderId("YOUR_SENDER_ID") // Your GCM Sender ID from Firebase Console
        .setProjectId("YOUR_PROJECT_ID"); // Your Project ID from Firebase Console
Seems promising
f
yes, that’s it
you can do the same thing on iOS
the google-services.json/plist is just a shortcut
c
I already did the plist setup on IOS, but I will surely try this out if I get issues with plist or maybe a new project. But I feel handling these many keys leaves room for manual error, missing characters when pasting 😆