Hello, is it possible to have product variants setup like android for Roku?
Since we have 1 app that has multiple brands (variants)
in android we select the flavor and it builds according to this.
All images, logos, strings are attached to the flavor(Variant)
Would this be possible?Because currently on each build we ned to replace all the information to relate to the brand we need.
Like Brand A has all images, text associated.
if we want Brand B we need to replace all of that and then build.
Thx
This is possible with VScode. Not as simple as adding flavors to gradle. You can set up multiple projects with the app specific code and in the launch.json include a folder with all your shared code.
An option could be storing in cloud an object (Json) with the settings for the current app, such as texts, urls for pictures, and configurations. The idea is to set a different end point for each one, or to have a bigger object with the settings for all variations. Then, you could set via manifest, the brand that your are pointing out, and by the use of urls like "http://repository.com/mybrandsconfig/{brandName}/home.title.for.first.tray" you could replace this previous set brand name to access your configs
hmm true, my goal was to automate the builds..
Like android i select assembleBrandADebug....and it nuilds that brand
there has to be a way to have multiple sub directories that have the images and icons..
so we select a manifiest and it loads that information.
Are the images and icons in the build? You can use the path as same as mentioned before.
For building build automatically, you can use a bash script. It could edit the manifest file with the brand name and select the desired folder to attach into the build. Then zip the file.
We use bash scripts for "customizing" builds for QA. We have different parameters to control the apps behavior (such as connecting to stage APIs, running with proxy, and so on). QA team uses a bash script for changing the app builds they receive, without needing to unzip, edit manifest file, and zip again.
I'm looking about assembleBrandDebug to a better understanding of what are you trying to do, but it seems similar to the ones that I'm telling you. If you need help with the script, I can give you and example 😉
ah, that is maybe the solution. we use azure devops. i can add bash. would be great to see the example.
really appreciate the help👍
Sure!
You must add a new property in the manifest file:
brand_build=brand_name
Your script file could be:
brand_variants.sh
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
cool, i will try it out!thx!