我想使用log4j将日志写入sdcard。如何专门使用gradle配置log4j?
我见过许多线程要求下载jar并将其添加为库,我找不到有关使用gradle配置log4j的好帖子。
这篇文章介绍了使用android-logging-log4j.jar的解决方案。
Gradle依赖项相同:
原始码
compile group: 'de.mindpipe.android', name: 'android-logging-log4j', version: '1.0.3'
compile group: 'log4j', name: 'log4j', version: '1.2.17'
更新:配置'compile'已过时,并已由'implementation'和'api'代替。
implementation 'de.mindpipe.android:android-logging-log4j:1.0.3'
implementation 'log4j:log4j:1.2.17'
本文收集自互联网,转载请注明来源。
如有侵权,请联系[email protected] 删除。
我来说两句