Skip to content
This repository was archived by the owner on Oct 11, 2021. It is now read-only.

Simple logback appender to log to Crashlytics for enhanced crash reports

License

Notifications You must be signed in to change notification settings

daberni/crashlytics-logback-appender

Repository files navigation

Build Status JCenter

Crashlytics Logback Appender

Simple logback appender to log to Crashlytics for enhanced crash reports.

! Archived !

Archived due to Fabric Crashlytics beeing superseded by Firebase Crashlytics, see https://github.com/finki001/firebase-crashlytics-logback-appender for same functionality.

Usage

Add as dependency in your build.gradle file:

implementation 'com.github.daberni:crashlytics-logback-appender:0.2.3'

After setting up Fabric/Crashlytics you have to setup the appender for correct logging.

public class AppApplication extends Application {
    
    @Override
    public void onCreate() {
        super.onCreate();

        Fabric.with(this, new Crashlytics());
        CrashlyticsLogbackAppender.setup();
    }
}

And don't forget the appender in your logback configuration!

<configuration>
	<appender name="Crashlytics" class="at.daberni.logback.appender.CrashlyticsLogbackAppender">
		<encoder>
			<pattern>%class.%method\(%file:%line\) - %msg%n</pattern>
		</encoder>
	</appender>

	<root level="DEBUG">
		<appender-ref ref="Crashlytics"/>
	</root>

</configuration>

License

This project is licensed under the Apache License Version 2.0.

About

Simple logback appender to log to Crashlytics for enhanced crash reports

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages