From ed6de0f73b7ceadefc68720a70375ac0db1263f1 Mon Sep 17 00:00:00 2001 From: Alvaro Blanco Cabrero Date: Tue, 24 Dec 2024 16:30:34 +0100 Subject: [PATCH 1/2] Add consumer Proguard rules to library --- applvsdklib/consumer-rules.pro | 94 +--------------------------------- 1 file changed, 2 insertions(+), 92 deletions(-) diff --git a/applvsdklib/consumer-rules.pro b/applvsdklib/consumer-rules.pro index e0f801f..013fc41 100644 --- a/applvsdklib/consumer-rules.pro +++ b/applvsdklib/consumer-rules.pro @@ -8,95 +8,5 @@ -dontwarn org.openjsse.javax.net.ssl.SSLSocket -dontwarn org.openjsse.net.ssl.OpenJSSE -##---------------Begin: Gson ---------- - -# For using GSON @Expose annotation --keepattributes *Annotation* - -# Gson specific classes --dontwarn sun.misc.** -#-keep class com.google.gson.stream.** { *; } - -# Prevent proguard from stripping interface information from TypeAdapter, TypeAdapterFactory, -# JsonSerializer, JsonDeserializer instances (so they can be used in @JsonAdapter) --keep class * extends com.google.gson.TypeAdapter --keep public class * implements java.lang.reflect.Type --keep class * implements com.google.gson.TypeAdapterFactory --keep class * implements com.google.gson.JsonSerializer --keep class * implements com.google.gson.JsonDeserializer - -# Prevent R8 from leaving Data object members always null --keepclasseswithmembers,allowobfuscation,includedescriptorclasses class * { - @com.google.gson.annotations.SerializedName ; -} - -# Retain generic signatures of TypeToken and its subclasses with R8 version 3.0 and higher. --keep,allowobfuscation,allowshrinking class com.google.gson.reflect.TypeToken --keep,allowobfuscation,allowshrinking class * extends com.google.gson.reflect.TypeToken - -##---------------End: Gson ---------- - -##---------------Begin: Retrofit 2.X ---------- -# Retrofit does reflection on generic parameters. InnerClasses is required to use Signature and -# EnclosingMethod is required to use InnerClasses. --keepattributes Signature, InnerClasses, EnclosingMethod - -# Retrofit does reflection on method and parameter annotations. --keepattributes RuntimeVisibleAnnotations, RuntimeVisibleParameterAnnotations - -# Keep annotation default values (e.g., retrofit2.http.Field.encoded). --keepattributes AnnotationDefault - -# Retain service method parameters when optimizing. --keepclassmembers,allowshrinking,allowobfuscation interface * { - @retrofit2.http.* ; -} - -# Ignore annotation used for build tooling. --dontwarn org.codehaus.mojo.animal_sniffer.IgnoreJRERequirement - -# Ignore JSR 305 annotations for embedding nullability information. --dontwarn javax.annotation.** - -# Guarded by a NoClassDefFoundError try/catch and only used when on the classpath. --dontwarn kotlin.Unit - -# Top-level functions that can only be used by Kotlin. --dontwarn retrofit2.KotlinExtensions --dontwarn retrofit2.KotlinExtensions$* - -# With R8 full mode, it sees no subtypes of Retrofit interfaces since they are created with a Proxy -# and replaces all potential values with null. Explicitly keeping the interfaces prevents this. --if interface * { @retrofit2.http.* ; } --keep,allowobfuscation interface <1> --if interface * { @retrofit2.http.* public *** *(...); } --keep,allowoptimization,allowshrinking,allowobfuscation class <3> - -# Keep generic signature of Call, Response (R8 full mode strips signatures from non-kept items). --keep,allowobfuscation,allowshrinking interface retrofit2.Call --keep,allowobfuscation,allowshrinking class retrofit2.Response --keep,allowobfuscation,allowshrinking class okhttp3.RequestBody --keep,allowobfuscation,allowshrinking class okhttp3.ResponseBody - -# With R8 full mode generic signatures are stripped for classes that are not -# kept. Suspend functions are wrapped in continuations where the type argument -# is used. --keep,allowobfuscation,allowshrinking class kotlin.coroutines.** { *; } -##---------------Begin: Retrofit 2.X ---------- - -##---------------Begin: OKHttp ---------- --keep class okhttp3.** { *; } --keep interface okhttp3.** { *; } --dontwarn retrofit2.** --dontwarn okhttp3.** - --keepclasseswithmembers class * { - @retrofit2.http.* ; -} -##---------------End: OKHttp ---------- - -##---------------Begin: Okio ---------- --dontwarn java.nio.file.* --dontwarn org.codehaus.mojo.animal_sniffer.IgnoreJRERequirement --dontwarn okio.** -##---------------End: Okio ---------- \ No newline at end of file +-keep class com.applivery.data.response.** { *; } +-keep class com.applivery.data.request.** { *; } \ No newline at end of file From 345a704f4aa0a4c92ac656b94338786e4d86d9ce Mon Sep 17 00:00:00 2001 From: Alvaro Blanco Cabrero Date: Tue, 24 Dec 2024 16:31:16 +0100 Subject: [PATCH 2/2] Bump library version to 3.8.3 --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index 6071583..99d4770 100644 --- a/build.gradle +++ b/build.gradle @@ -57,5 +57,5 @@ apply from: "${rootDir}/scripts/publish-root.gradle" ext { PUBLISH_GROUP_ID = 'com.applivery' - PUBLISH_VERSION = '3.8.2' + PUBLISH_VERSION = '3.8.3' }