2022-03-22 14:35:23 +00:00
|
|
|
plugins {
|
|
|
|
kotlin("multiplatform")
|
|
|
|
id("com.android.library")
|
|
|
|
kotlin("plugin.serialization") version "1.4.10"
|
|
|
|
}
|
|
|
|
|
|
|
|
kotlin {
|
|
|
|
android()
|
|
|
|
|
|
|
|
listOf(
|
|
|
|
iosX64(),
|
|
|
|
iosArm64(),
|
|
|
|
//iosSimulatorArm64() sure all ios dependencies support this target
|
|
|
|
).forEach {
|
|
|
|
it.binaries.framework {
|
|
|
|
baseName = "shared"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
sourceSets {
|
|
|
|
val commonMain by getting {
|
|
|
|
dependencies {
|
2022-05-21 08:41:09 +00:00
|
|
|
implementation("io.ktor:ktor-client-core:2.0.1")
|
|
|
|
implementation("io.ktor:ktor-client-content-negotiation:2.0.1")
|
|
|
|
implementation("io.ktor:ktor-serialization-kotlinx-json:2.0.1")
|
|
|
|
implementation("io.ktor:ktor-client-logging:2.0.1")
|
2022-03-22 14:35:23 +00:00
|
|
|
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:1.6.0")
|
2022-05-21 08:41:09 +00:00
|
|
|
implementation("io.ktor:ktor-client-auth:2.0.1")
|
2022-03-22 14:35:23 +00:00
|
|
|
implementation("org.jsoup:jsoup:1.14.3")
|
2022-07-17 23:28:56 +00:00
|
|
|
|
|
|
|
//Dependency Injection
|
|
|
|
implementation("org.kodein.di:kodein-di:7.12.0")
|
2022-07-18 21:25:10 +00:00
|
|
|
|
|
|
|
//Settings
|
|
|
|
implementation("com.russhwolf:multiplatform-settings-no-arg:0.9")
|
|
|
|
|
|
|
|
//Logging
|
|
|
|
implementation("io.github.aakira:napier:2.6.1")
|
2022-08-17 12:51:00 +00:00
|
|
|
|
|
|
|
// Network information
|
|
|
|
implementation("com.github.ln-12:multiplatform-connectivity-status:1.1.0")
|
2022-03-22 14:35:23 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
val commonTest by getting {
|
|
|
|
dependencies {
|
|
|
|
implementation(kotlin("test-common"))
|
|
|
|
implementation(kotlin("test-annotations-common"))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
val androidMain by getting {
|
|
|
|
dependencies {
|
2022-05-21 08:41:09 +00:00
|
|
|
implementation("io.ktor:ktor-client-android:2.0.1")
|
2022-03-22 14:35:23 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
val androidTest by getting {
|
|
|
|
dependencies {
|
|
|
|
implementation(kotlin("test-junit"))
|
|
|
|
implementation("junit:junit:4.13.2")
|
|
|
|
}
|
|
|
|
}
|
|
|
|
val iosX64Main by getting
|
|
|
|
val iosArm64Main by getting
|
|
|
|
//val iosSimulatorArm64Main by getting
|
|
|
|
val iosMain by creating {
|
|
|
|
dependsOn(commonMain)
|
|
|
|
iosX64Main.dependsOn(this)
|
|
|
|
iosArm64Main.dependsOn(this)
|
|
|
|
//iosSimulatorArm64Main.dependsOn(this)
|
|
|
|
}
|
|
|
|
val iosX64Test by getting
|
|
|
|
val iosArm64Test by getting
|
|
|
|
//val iosSimulatorArm64Test by getting
|
|
|
|
val iosTest by creating {
|
|
|
|
dependsOn(commonTest)
|
|
|
|
iosX64Test.dependsOn(this)
|
|
|
|
iosArm64Test.dependsOn(this)
|
|
|
|
dependencies {
|
2022-05-21 08:41:09 +00:00
|
|
|
implementation("io.ktor:ktor-client-ios:2.0.1")
|
2022-03-22 14:35:23 +00:00
|
|
|
}
|
|
|
|
//iosSimulatorArm64Test.dependsOn(this)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
android {
|
|
|
|
compileSdk = 31
|
|
|
|
sourceSets["main"].manifest.srcFile("src/androidMain/AndroidManifest.xml")
|
|
|
|
defaultConfig {
|
|
|
|
minSdk = 21
|
|
|
|
targetSdk = 31
|
|
|
|
}
|
|
|
|
}
|