chore(r8): clean up ProGuard rules and enable Compose Hot Reload (#5139)

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
James Rich 2026-04-14 22:26:39 -05:00 committed by GitHub
parent 401f59489a
commit 60ff495037
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 5 additions and 18 deletions

View file

@ -171,8 +171,6 @@ configure<ApplicationExtension> {
} else {
signingConfig = signingConfigs.getByName("debug")
}
isMinifyEnabled = true
isShrinkResources = true
isDebuggable = false
}
}

View file

@ -13,6 +13,10 @@
# Open-source no need to obfuscate
-dontobfuscate
# Dump the full merged R8 configuration (app rules + all library consumer rules)
# for auditing. Inspect this file after a release build to see what libraries inject.
-printconfiguration build/outputs/mapping/r8-merged-config.txt
# ---- Networking (transitive references from Ktor) ---------------------------
-dontwarn org.conscrypt.**
@ -43,13 +47,3 @@
# R8 exception-class merging.
-keep class org.jetbrains.compose.resources.** { *; }
-keep class org.meshtastic.core.resources.** { *; }
# Compose Animation: prevent R8 from merging animation spec classes (easing
# curves, transition specs, Animatable internals) which can cause animations to
# silently snap in release builds.
#
# We use a full -keep here without allowshrinking/allowobfuscation. While it
# might keep some unused transition APIs, R8's aggressive shrinking is known
# to incorrectly remove internal states or merging empty transitions (like None)
# causing AnimatedVisibility and others to snap.
-keep class androidx.compose.animation.** { *; }

View file

@ -147,12 +147,6 @@
-keep class org.jetbrains.compose.resources.** { *; }
-keep class org.meshtastic.core.resources.** { *; }
# ---- Compose Animation (anti-merge) ----------------------------------------
# Prevent ProGuard from merging animation spec class hierarchies (same issue
# as R8 on Android). We use a full keep to prevent incorrect tree-shaking
# of internal transitions.
-keep class androidx.compose.animation.** { *; }
# ---- AboutLibraries ---------------------------------------------------------

View file

@ -29,3 +29,4 @@ org.gradle.jvmargs=-Xmx8g -XX:+UseParallelGC -XX:MaxMetaspaceSize=2g -XX:+HeapDu
org.gradle.parallel=true
org.gradle.vfs.watch=true
org.gradle.welcome=never
compose.hot.reload=true