diff --git a/README.md b/README.md index c9b1247..b2fa3e8 100644 --- a/README.md +++ b/README.md @@ -22,8 +22,10 @@ also you can run with `watch` instead of `build` to build with any code change. Generate apk with: ``` -flutter build apk -t lib/mainProd.dart +flutter build apk -t lib/mainProd.dart --flavor production ``` +also you can run with `-t lib/mainDev.dart --flavor development`. More info about flavors [here](https://medium.com/@salvatoregiordanoo/flavoring-flutter-392aaa875f36). + ## Testing Run `flutter test` for doing unit testing. diff --git a/android/app/build.gradle b/android/app/build.gradle index 2291822..3994b12 100644 --- a/android/app/build.gradle +++ b/android/app/build.gradle @@ -55,6 +55,19 @@ android { } } + flavorDimensions "flavor-type" + + productFlavors { + development { + dimension "flavor-type" + applicationIdSuffix ".dev" + versionNameSuffix "-dev" + } + production { + dimension "flavor-type" + } + } + } flutter {