From 7d87777bf89a8c79efa8c505455c62ae1ba1cc32 Mon Sep 17 00:00:00 2001 From: topjohnwu Date: Sat, 1 Jun 2019 01:13:29 -0700 Subject: [PATCH] Improve proguard rules --- app/build.gradle | 2 ++ app/proguard-rules.pro | 6 ++---- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/app/build.gradle b/app/build.gradle index a9d167334..e0787350e 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -23,6 +23,8 @@ android { buildTypes { release { + minifyEnabled true + shrinkResources true proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro', 'proguard-moshi.pro', 'proguard-kotlin.pro' } diff --git a/app/proguard-rules.pro b/app/proguard-rules.pro index 00645821b..6e6d2e170 100644 --- a/app/proguard-rules.pro +++ b/app/proguard-rules.pro @@ -16,10 +16,8 @@ # public *; #} -# Internal app data and IO helper constructors --keep class com.topjohnwu.magisk.model.entity.** { *; } --keep class com.topjohnwu.magisk.data.database.base.** { public (...); } --keep class com.topjohnwu.magisk.data.network.** { public (...); } +# Retrofit classes +-keep,allowobfuscation class com.topjohnwu.magisk.data.network.** # Snet -keepclassmembers class com.topjohnwu.magisk.utils.ISafetyNetHelper { *; }