Android `templateMergeStrategy` in strings.xml

What does the templateMergeStrategy property mean in an Android resource?

eg. in the google maps API key file

 <string name="google_maps_key" templateMergeStrategy="preserve" translatable="false"> AIza.......some...secret...key... </string> 

I would expect a simple google search (or duckduckgo) to give me results, but unfortunately it seems to me that this gives me Google Maps API questions.

Unfortunately, Android Developer Docs on "String Resources" are also missing in this section.

+7
android android gradle
source share
3 answers

From change log

Used to overwrite instructions in the Google Maps template. Subsequent runs of the template always update instructions using the user-defined current values ​​of the keystore.

The Maps instructions for deep linking in the Google stream of the developer console have also changed, which makes it easier to create keys.

+3
source share

This means that the Android Studio template engine will save this line when a new Google Maps action is created, so you won’t lose your key.

+1
source share

Well, I found the following in Google Code

After committing in google code states

Used to overwrite instructions in the Google Maps template. Subsequent runs of the template always update instructions using the user-defined current values ​​of the keystore.

0
source share

All Articles