build.gradle:
buildTypes {
release {
minifyEnabled true
shrinkResources true
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
signingConfig signingConfigs.SginConfig
}
}
I don’t want Proguard to optimize or distort my code as it causes me a lot of problems. I only want to remove the log calls and allow the reduction of unused resources.
proguard-rules.pro:
-assumenosideeffects class android.util.Log {
public static boolean isLoggable(java.lang.String, int);
public static int w(...);
public static int d(...);
public static int e(...);
}
Adding the above code to proguard-rules.proworks only if I set getDefaultProguardFile from ('proguard-android.txt')to('proguard-android-optimize.txt')
But, setting it to proguard-android-optimize.txt, optimization flags will be included, which I do not need in my case.
So, how can I just turn off resource logging and compression without Proguard doing any minimization or optimization of my code?