Fix android proGuard issue

This commit is contained in:
LollipopKit
2021-10-26 14:36:58 +08:00
parent 18ff844b5e
commit 42fa67fbfc
4 changed files with 14 additions and 12 deletions

View File

@@ -69,7 +69,9 @@ android {
release {
// TODO: Add your own signing config for the release build.
// Signing with the debug keys for now, so `flutter run --release` works.
signingConfig signingConfigs.debug
signingConfig signingConfigs.release
minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}

7
android/app/proguard-rules.pro vendored Normal file
View File

@@ -0,0 +1,7 @@
-keep class io.flutter.app.** { *; }
-keep class io.flutter.plugin.** { *; }
-keep class io.flutter.util.** { *; }
-keep class io.flutter.view.** { *; }
-keep class io.flutter.** { *; }
-keep class io.flutter.plugins.** { *; }
-keep class com.jcraft.** { *; }