Android Log 日志收集库
Gradle
dependencies{
implementation 'com.soarsy:logCollector:1.0.0'
}
private void init() {
context = getApplicationContext();
//崩溃日志初始化(默认开启)
CrashHelper.getInstance().init(context);
//建议在需调试时打开
////普通log日志初始化
// LogcatHelper.getInstance().init(context);
////开启普通日志输出
//LogcatHelper.getInstance().start();
}
-
getExternalFilesDir
/sdcard/Android/data/(application package)/files/Logcat/logcat.log
-
getFilesDir
/data/data/(application package)/files/Logcat/logcat.log