Install

Kodein-Log uses the new gradle native dependency model. Thus, we highly recommend to use Gradle 6 or higher.

Kotlin/Multiplatform

Kodein-Log supports the following targets:
jvm, iosArm32, iosArm64, iosX64, JS, tvosarm64, tvosx64, watchosarm32, watchosarm64, watchosx86, linuxArm32Hfp, linuxMips32, linuxMipsel32, linuxX64, macosX64, mingwX64.

In your build.gradle.kts file, add the Maven Central repository:

repositories {
    mavenCentral()
}

Then add the dependency:

kotlin {
    sourceSets {
        commonMain {
            dependencies {
                implementation("org.kodein.log:kodein-log:0.10.2")
            }
        }
    }
}

If you are NOT using Gradle 6+, you should declare the use of the Gradle Metadata experimental feature

settings.gradle.kts
enableFeaturePreview("GRADLE_METADATA")

JVM & Android

On the JVM, Kodein-Log is compatible with both standard JVM and Android environments, with the same configuration.

First, add the Maven Central repository:

repositories {
    mavenCentral()
}

Then add the dependency:

dependencies {
    implementation("org.kodein.log:kodein-log-jvm:0.10.2")
}

JavaScript

Add the Maven Central repository:

repositories {
    mavenCentral()
}

Then add the dependency:

dependencies {
    implementation("org.kodein.log:kodein-log-js:0.10.2")
}