1. Are you ready for the Galaxy S20? Here is everything we know so far!

Bug with Proguard minifyEnabled on A/S 1.5.1 ?

Discussion in 'Android Development' started by ac4android, Mar 17, 2016.

  1. ac4android

    ac4android Well-Known Member
    Thread Starter

    This might be a bug, don't know whether it has been reported.

    I tried to compile an apk-release.apk using "Build -> Generate signed APK..." and A/S 1.5.1 threw this error:
    Error:Execution failed for task ':app:transformClassesAndResourcesWithProguardForRelease'. > java.io.IOException: Please correct the above warnings first

    I went into build.gradle and disabled ninifyEnabled, like this :
    Code (Text):
    2. buildTypes {
    3.     release {
    4.         minifyEnabled false
    5.         proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
    6.     }
    7. }
    Then it worked well.

    QUESTION: I'd rather have proguard minifyEnabled to scramble the code, is there a work around?


Share This Page