From de27b4b109e624a68619b4016f8b65edc2015c3a Mon Sep 17 00:00:00 2001 From: kitadai31 <90122968+kitadai31@users.noreply.github.com> Date: Wed, 3 Sep 2025 05:12:06 +0900 Subject: [PATCH] build: Clean up ProGuard rules (#2663) --- app/proguard-rules.pro | 67 ++++++------------------------------------ 1 file changed, 9 insertions(+), 58 deletions(-) diff --git a/app/proguard-rules.pro b/app/proguard-rules.pro index b9b9c1af..2fc38c4f 100644 --- a/app/proguard-rules.pro +++ b/app/proguard-rules.pro @@ -1,63 +1,14 @@ -# Add project specific ProGuard rules here. -# You can control the set of applied configuration files using the -# proguardFiles setting in build.gradle.kts.kts. -# -# For more details, see -# http://developer.android.com/guide/developing/tools/proguard.html - -dontobfuscate -# Required for serialization to work properly --if @kotlinx.serialization.Serializable class ** --keepclassmembers class <1> { - static <1>$Companion Companion; -} --if @kotlinx.serialization.Serializable class ** { - static **$* *; -} --keepclassmembers class <2>$<3> { - kotlinx.serialization.KSerializer serializer(...); -} --if @kotlinx.serialization.Serializable class ** { - public static ** INSTANCE; -} --keepclassmembers class <1> { - public static <1> INSTANCE; - kotlinx.serialization.KSerializer serializer(...); -} +-keep class app.revanced.manager.patcher.runtime.process.* { *; } +-keep class app.revanced.manager.plugin.** { *; } +-keep class app.revanced.patcher.** { *; } +-keep class com.android.tools.smali.** { *; } +-keep class kotlin.** { *; } +-keepnames class com.android.apksig.internal.** { *; } +-keepnames class org.xmlpull.** { *; } -# This required for the process runtime. --keep class app.revanced.manager.patcher.runtime.process.* { - *; -} -# Required for the patcher to function correctly --keep class app.revanced.patcher.** { - *; -} --keep class brut.** { - *; -} --keep class org.xmlpull.** { - *; -} --keep class kotlin.** { - *; -} --keep class org.jf.** { - *; -} --keep class com.android.** { - *; -} --keep class app.revanced.manager.plugin.** { - *; -} - --dontwarn com.google.auto.value.** +-dontwarn com.google.j2objc.annotations.* -dontwarn java.awt.** -dontwarn javax.** --dontwarn org.slf4j.** --dontwarn it.skrape.fetcher.* --dontwarn com.google.j2objc.annotations.* - --keepattributes RuntimeVisibleAnnotations,AnnotationDefault \ No newline at end of file +-dontwarn org.slf4j.** \ No newline at end of file