Disable Crashlytics For Android App debug builds

Hire us for your custom mobile application and Web Application development needs . You can be assured your final deliverable, no matter the technology its built on, will be secure, scalable and sustainable in whatever environment its hosted.

WhatsApp : +918500018686 :: skype: sales@sipcosystems.com

 

Tip Of The Day:

 

Crashlytics is an excellent app debugging and crash analysis tool. Sometimes we may want to disable crashlytics for debug builds which speeds up gradle builds. Setting ext.enableCrashlytics = false  will  disable sending a mapping file to crashlytics backend 

debug {
    ext.enableCrashlytics = false
    debuggable true

Also  add below line in your app mainactivity  OnCreate  method  where we usually call Fabric.with(this, new Crashlytics());

Fabric.with(this, new Crashlytics.Builder().core(new CrashlyticsCore.Builder().disabled(BuildConfig.DEBUG).build()).build());

 

 

Or you can completely disable crashlytics library for debug builds by adding releaseImplementation to app build.gradle

dependencies {
   ...
   releaseImplementation 'com.crashlytics.sdk.android:crashlytics:2.10.1' // update your version
}

 

 

Leave a Reply

Your email address will not be published. Required fields are marked *

Back To Top