Search code examples
firebasecrashlyticsfirebase-crash-reporting

How to upload a mapping file to Firebase Crashlytics?


In the old Crash reporting - there is easy way to upload. i didn't find it in the Crashlytics section


Solution

  • UPDATE: Firebase update their docs: see here

    There is no need anymore to manually upload mapping file.

    1 - To preserve the info Crashlytics needs for readable crash reports, add the following lines to your config file:

    -keepattributes *Annotation*
    -keepattributes SourceFile,LineNumberTable
    -keep public class * extends java.lang.Exception
    

    2 - To let Crashlytics automatically upload the ProGuard or DexGuard mapping file, remove this line from the config file (app/proguard-rules.pro):

    -printmapping mapping.txt
    

    For faster builds with ProGuard, exclude Crashlytics. Add the following lines to your config file:

    -keep class com.crashlytics.** { *; }
    -dontwarn com.crashlytics.**