How to make the content of google-services.json file configurable

1,083 views
Skip to first unread message

muha...@gmail.com

unread,
Sep 2, 2022, 3:20:37 AM9/2/22
to Firebase Google Group
I would like to make the content for the google-serviee.json configurable meaning change the file from

img1_attached 

to

{ "project_info": { "project_number": $project_number, "project_id": $project_id, "storage_bucket": $project_id }, "client": [ { "client_info": { "mobilesdk_app_id": $mobilesdk_app_id, "android_client_info": { "package_name": $package_name } }, "oauth_client": [ { "client_id": $client_id, "client_type": 3 } ], "api_key": [ { "current_key": $current_key } ], "services": { "appinvite_service": { "other_platform_oauth_client": [ { "client_id": $client_id, "client_type": 3 } ] } } } ], "configuration_version": "1" }

and during the ADO I will replace the variables with the values.

But when I Build>Rebuild Project the build has failed enter image description here

it failed because the building process will check if the google-sercices exist and also has the package name = "org.fooshtech.fcm" , Is there a way to make the content of this file dynamically 'configurable'


google_service.png
Reply all
Reply to author
Forward
0 new messages