Skip to content

Commit

Permalink
Merge pull request #6168 from seadowg/line-numbers
Browse files Browse the repository at this point in the history
Fix line numbers in Crashlytics reports
  • Loading branch information
grzesiek2010 authored Jun 6, 2024
2 parents 4abda64 + dcbd423 commit 1e4ed48
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 3 deletions.
6 changes: 3 additions & 3 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
- checkout
- run:
name: Generate combined build.gradle file for cache key
command: cat build.gradle */build.gradle .circleci/gradle.properties .circleci/config.yml buildSrc/src/main/java/dependencies/Dependencies.kt buildSrc/src/main/java/dependencies/Versions.kt > deps.txt
command: cat build.gradle */build.gradle */build.gradle.kts .circleci/gradle.properties .circleci/config.yml buildSrc/src/main/java/dependencies/Dependencies.kt buildSrc/src/main/java/dependencies/Versions.kt > deps.txt
- restore_cache:
keys:
- compile-deps-{{ checksum "deps.txt" }}
Expand Down Expand Up @@ -230,8 +230,8 @@ jobs:
command: ./gradlew assembleSelfSignedRelease

- run:
name: Check APK size isn't larger than 10.9MB
command: if [ $(ls -l collect_app/build/outputs/apk/selfSignedRelease/*.apk | awk '{print $5}') -gt 10900000 ]; then exit 1; fi
name: Check APK size isn't larger than 11.5MB
command: ./check-size.sh

- run:
name: Copy APK to predictable path for artifact storage
Expand Down
6 changes: 6 additions & 0 deletions check-size.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
set -e

if [ $(ls -l collect_app/build/outputs/apk/selfSignedRelease/*.apk | awk '{print $5}') -gt 11500000 ];then
echo "APK increased to $(ls -l collect_app/build/outputs/apk/selfSignedRelease/*.apk | awk '{print $5}') bytes!"
exit 1
fi
3 changes: 3 additions & 0 deletions collect_app/proguard-rules.txt
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,6 @@
-keepnames class okhttp3.internal.publicsuffix.PublicSuffixDatabase
-dontwarn org.codehaus.mojo.animal_sniffer.*
-dontwarn okhttp3.internal.platform.ConscryptPlatform

# Keep line numbers for Crashlytics https://stackoverflow.com/questions/38529304/android-crashlytics-sending-incorrect-line-number
-keepattributes SourceFile,LineNumberTable

0 comments on commit 1e4ed48

Please sign in to comment.