https://github.com/vanlooverenkoen/riddle
Riddle is a logging library to send your logs to another app
https://github.com/vanlooverenkoen/riddle
android-app android-library logger realtime-updates
Last synced: 3 months ago
JSON representation
Riddle is a logging library to send your logs to another app
- Host: GitHub
- URL: https://github.com/vanlooverenkoen/riddle
- Owner: vanlooverenkoen
- License: apache-2.0
- Created: 2018-10-30T07:14:43.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2019-07-30T12:35:16.000Z (almost 6 years ago)
- Last Synced: 2025-01-20T09:26:24.019Z (5 months ago)
- Topics: android-app, android-library, logger, realtime-updates
- Language: Kotlin
- Size: 90.8 KB
- Stars: 4
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.MD
- License: LICENSE
Awesome Lists containing this project
README
### Riddle ###
Riddle Logger:[  ](https://bintray.com/vanlooverenkoen/maven/riddle/_latestVersion)
Riddle Network Interceptor:
[  ](https://bintray.com/vanlooverenkoen/maven/riddle-network-interceptor/_latestVersion)
**What does it do?**
Riddle is a library you can import in your project to send your logs to the Riddle app. The Riddle app will be available soon. An overlay will be shown in Android where you can view all the logs by your app. You can also filter on certain parameters.
**How To Use**
Import in root gradle
allprojects {
repositories {
...
maven { url "https://dl.bintray.com/vanlooverenkoen/maven" }
...
}
}Apply the plugin by adding next command at the top of your app/build.gradle file
dependencies {
implementation "be.vanlooverenkoen:riddle:0.0.5"
implementation "be.vanlooverenkoen:riddle-network-interceptor:0.0.2"
}***Setup Logger***
in your application file add the following. By default are all logTypes enabled. (Debug, Info, Verbose, Warn, Error, Assert). Make sure you only enable Riddle for debug builds.
if (BuildConfig.DEBUG) {
Riddle.with(this)
}***Configuration Logger***
If you want to enable or disable certain log types you need to pass only the logtypes you want to enable. The configuration below will enable logging for Debug, Error and Verbose. (Info, Warn and Assert will be disabled)
if (BuildConfig.DEBUG) {
Riddle.with(this)
.setLogTypes(RiddleLogType.DEBUG,
RiddleLogType.ERROR,
RiddleLogType.VERBOSE)
}***Usage Logger***
Just call the methods on Riddle:
Riddle.d("Tag", "Debug Content")
Riddle.i("Tag", "Info Content")
Riddle.v("Tag", "Verbose Content")
Riddle.w("Tag", "Warn Content")
Riddle.a("Tag", "Assert Content")
Riddle.e("Tag", "Error Content")
***Setup Network Interceptor***in your application file add the following. Make sure you only enable Riddle for debug builds.
if (BuildConfig.DEBUG) {
OkHttpClient.Builder()
.addInterceptor(RiddleNetworkInterceptor(context, baseUrl))
.build()
}