Created a demo application for Ionic and added the android platform to the same. Imported this very same android project under the platforms directory into my Android Studio for further modifications at the native end. Below is my project structure:
+DemoApp
-build
-cordova
-CordovaLib
-gradle
-libs
-platform_www
-res
-src
-AndroidManifest.xml
-build.gradle
-proguard-android.txt
-project.properties
-settings.gradle
added below lines in my build.gradle to enable proguard:
buildTypes {
release {
signingConfig signingConfigs.release
minifyEnabled true
debuggable false
shrinkResources true
proguardFiles 'proguard-android.txt'
}
}
However, the issue that I am facing is that on generating a signed APK, my build does not consider the Proguard files and its rules.I do not see any proguard operations being conducted in the gradle console. The mapping.txt file isn’t generated in the build->outputs->release folder either. How to I enable proguard in my project so as to obfuscate the java files in the src folder?