Maintaining AndroidManifest.xml in Git

As everything in platform/ directory is gitignored and we’re told to update platforms/android/AndroidManifest.xml for some things such as versioning for Google Play store ( i wondered what the best practice is for maintaining settings between multiple developers and machines on a project?

I tried to bodge inserting stuff in to the manifest using a hook, but my string replacement goes bad as the Android Manifest is never rebuilt from scratch each time so my hook is adding the same thing in over and over again. doh!

That guide is wrong on that point. You don’t need to specify an Android version code because Cordova will automatically generate one for you based on the version set in config.xml. You can also explicitly specify an Android version code in config.xml if you prefer. Either way, no need to edit AndroidManifest.xml directly.


There’s already an open issue for this inaccuracy in the guide: