Kotlin - Timber Log Live Template
/* | |
Go to Android Studio Preferences | |
Editor > Live Template > Kotlin | |
Duplicate "soutp" and use following template for `$FORMAT`. | |
``` | |
timber.log.Timber.d($FORMAT$) | |
``` | |
Applicable in kotlin statement (it should be pre-selected for you, since you copied `soutp`) | |
*/ | |
groovyScript("def params = _2.collect {it + ' = [${' + it + '}]'}.join(', '); return '\"' + _1 + '() called' + (params.empty ? '' : ' with: ' + params) + '\"'", kotlinFunctionName(), functionParameters()) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment