Reputation: 6622
I already have
2 flavours (staging, production)
2 buildTypes (debug, release)
beyond that, I want to have different variants for, say, different vendors. like a production-release build for samsung and htc. is it possible through build scripts?
PS: I don't want to use 3rd party plugin like this
Upvotes: 3
Views: 313
Reputation: 13466
You could use flavor dimensions.
android {
flavorDimensions 'environment', 'vendor'
productFlavors {
staging {
flavorDimension 'environment'
}
production {
flavorDimension 'environment'
}
htc {
flavorDimension 'vendor'
}
samsung {
flavorDimension 'vendor'
}
}
}
Upvotes: 3