you can choose the release variant from the Build Variants view and build it from the GUI:
now please take a look for Your configuration build.gradle file for proguard implementation. It can be module level or the project level.
buildTypes {
debug {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-
rules.txt'
}
}
The configuration shown is for debug level you can write your own build scripts like shown below inside buildTypes:
myproductionbuild{
minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-
rules.txt'
}
Better to have your dedug with minifyEnabled false and productionbuild and other builds as minifyEnabled true .