From d9080195ab246fb209961d97d66e3bd1e4f9f218 Mon Sep 17 00:00:00 2001 From: kalarina Date: Sun, 25 Oct 2026 14:46:33 +0200 Subject: [PATCH] Let R8 obfuscate release builds Shrinks the dex further. Crash reports keep file names and line numbers; the mapping file restores the names and is kept with the CI artifacts. --- .github/workflows/ci.yml | 4 +++- app/proguard-rules.pro | 5 +++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7708869..90e018b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -47,5 +47,7 @@ jobs: if: always() with: name: apk - path: app/build/outputs/apk/**/*.apk + path: | + app/build/outputs/apk/**/*.apk + app/build/outputs/mapping/release/mapping.txt if-no-files-found: ignore diff --git a/app/proguard-rules.pro b/app/proguard-rules.pro index 8a61059..251fc50 100644 --- a/app/proguard-rules.pro +++ b/app/proguard-rules.pro @@ -1,3 +1,4 @@ -# Readable stack traces in crash reports +# File names and line numbers stay in stack traces, names are obfuscated. To read a crash +# report, build the same release (builds are reproducible) and run +# retrace app/build/outputs/mapping/release/mapping.txt crash.txt -keepattributes SourceFile,LineNumberTable --dontobfuscate