Android Gradle Build Configuration

Build Types, Product Flavors, and Build Variants, what’s the difference?

Evana Puig
The Startup

--

With the help of Gradle and the Android plugin, you can easily automate processes that in the past needed to be manually done and a lot of time-consuming activities. Among the advantages of these configurations, we find Android Gradle Build Configuration, with which you can get different versions of your app with variations for things like testing, using different backend endpoints, switching assets, or enabling some locked features.

When talking about these variations we find three main terms “build type”, “product flavour” and “build variant”. Let’s explore each of these and use-cases for one over another.

Build Type

Build Types are mainly for development stages, they allow you to have an app version for each of the steps of your development process. This stages vary from project to project but refer to steps like:

  • Develop or Debug
  • Testing or QA
  • Release
  • Release Candidate often referred with the acronym RC

--

--

Evana Puig
The Startup

Mobile Developer expert in Android and iOS, with 10 years of experience. Visit me at evanapuig.com. Author, and topic master at raywenderlich.com.