0

I am changing the build name every time I create a new build. And that happens almost every hour. How can I change the application label in the manifest file every time I create a new build?

As an example: Build A named as BuildA01AB and the second build is named as BuildA01AC and so on.

Thanks.

Ahmed
  • 2,966
  • 7
  • 42
  • 69
  • Why do you want to change the label for every build? If you are just using this value to identify a build number in the app (say on an about or settings screen), there are better ways to go about it. – Bryan Herbst Sep 25 '14 at 19:43
  • You could try using the placeholder facility in [the manifest merging process](http://tools.android.com/tech-docs/new-build-system/user-guide/manifest-merger) to generate a label value that you then apply to the `android:label` attribute. That being said, I agree with Tanis.7x, that this is a rather odd request. – CommonsWare Sep 25 '14 at 19:45
  • @Tanis.7x: I agree but as an example each build with additional/different code should have a different build version for the nightly releases. Each nightly release has a incremental/different version number. – Ahmed Sep 25 '14 at 20:25
  • @CommonsWare: Thank you. manifest merging process sounds like a good idea. But is this something that will deprecated in the up coming releases of gradle or if its gonna stay for long? Other than that, the bigger question is, If Ill have to merge the manifest manually just because of introducing custom labels? – Ahmed Sep 25 '14 at 20:33
  • "But is this something that will deprecated in the up coming releases of gradle" -- I doubt it. "If Ill have to merge the manifest manually" -- I have no idea what you mean by this, sorry. – CommonsWare Sep 25 '14 at 20:34
  • In the above mentioned link, to revert to the old manifest merger, please add to your build.gradle the following configuration : android { useOldManifestMerger true } so my question is that to use a placeholder facility do we need to turn on the OldManifestMerger? – Ahmed Sep 25 '14 at 20:48
  • http://stackoverflow.com/questions/24785270/how-to-change-app-name-per-gradle-build-type – Shane Oct 27 '16 at 08:21

0 Answers0