Skip to content

Commit

Permalink
Add proguard rules not to obfuscate & shrink necessary files on relea…
Browse files Browse the repository at this point in the history
…se mode
  • Loading branch information
erdemyerebasmaz committed Jan 4, 2024
1 parent 0037062 commit 5c24869
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 0 deletions.
5 changes: 5 additions & 0 deletions android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,11 @@ android {
signingConfig signingConfigs.debug
resValue "string", "app_name", "Breez Cloud"
resValue "string", "breezApiKey", envVariables.API_KEY

proguardFiles(
getDefaultProguardFile("proguard-android.txt"),
"proguard-rules.pro"
)
}
}
}
Expand Down
16 changes: 16 additions & 0 deletions android/app/proguard-rules.pro
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Tinylog
-keepnames interface org.tinylog.**
-keepnames class * implements org.tinylog.**
-keepclassmembers class * implements org.tinylog.** { <init>(...); }

-dontwarn dalvik.system.VMStack
-dontwarn java.lang.**
-dontwarn javax.naming.**
-dontwarn sun.reflect.Reflection

# JNA
-keep class com.sun.jna.** { *; }
-keep class * implements com.sun.jna.** { *; }

# Other
-dontoptimize

0 comments on commit 5c24869

Please sign in to comment.