Skip to content

Commit

Permalink
Update example
Browse files Browse the repository at this point in the history
  • Loading branch information
Foso committed Aug 12, 2024
1 parent e9abe1c commit d2e2142
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 20 deletions.
5 changes: 3 additions & 2 deletions example/MultiplatformExample/androidApp/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ android {
compileSdk = 34
defaultConfig {
applicationId = "com.example.myapplication.android"
namespace = "com.example.myapplication.android"
minSdk = 21
targetSdk = 34
versionCode = 1
Expand All @@ -24,11 +25,11 @@ android {
}

kotlinOptions {
jvmTarget= "1.8"
jvmTarget = "1.8"
}
}

dependencies {
implementation(project(":shared"))
implementation("com.google.android.material:material:1.12.0")
}
}
8 changes: 4 additions & 4 deletions example/MultiplatformExample/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
buildscript {
repositories {
//mavenLocal()
// mavenLocal()
gradlePluginPortal()
google()
mavenCentral()
Expand All @@ -10,14 +10,14 @@ buildscript {
}
dependencies {
classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:2.0.0")
classpath("com.android.tools.build:gradle:7.3.1")
classpath("org.jetbrains.kotlin:kotlin-serialization:2.0.0")
classpath("com.android.tools.build:gradle:8.2.0")
classpath("org.jetbrains.kotlin:kotlin-serialization:2.0.10")
}
}

allprojects {
repositories {
//mavenLocal()
// mavenLocal()
google()
mavenCentral()
maven {
Expand Down
25 changes: 12 additions & 13 deletions example/MultiplatformExample/shared/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ plugins {
kotlin("multiplatform")
kotlin("native.cocoapods")
id("com.android.library")
id("com.google.devtools.ksp") version "2.0.0-1.0.22"
id("com.google.devtools.ksp") version "2.0.0-1.0.24"
id("kotlinx-serialization")
id("de.jensklingenberg.ktorfit") version "2.0.0"
id("de.jensklingenberg.ktorfit") version "2.0.1"
}

ktorfit {
Expand All @@ -15,8 +15,8 @@ ktorfit {
}

version = "1.0"
val ktorVersion = "2.3.11"
val ktorfitVersion = "2.0.0"
val ktorVersion = "3.0.0-beta-2"
val ktorfitVersion = "2.0.1"

kotlin {
jvmToolchain(8)
Expand Down Expand Up @@ -45,14 +45,14 @@ kotlin {
sourceSets {
val commonMain by getting {
dependencies {
implementation("de.jensklingenberg.ktorfit:ktorfit-lib:$ktorfitVersion")
//implementation("de.jensklingenberg.ktorfit:ktorfit-lib-light:$ktorfitVersion")
implementation("de.jensklingenberg.ktorfit:ktorfit-lib-ktor-3.0.0-beta-2:$ktorfitVersion")
// implementation("de.jensklingenberg.ktorfit:ktorfit-lib-light:$ktorfitVersion")
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:1.8.1")
implementation("de.jensklingenberg.ktorfit:ktorfit-converters-response:$ktorfitVersion")
implementation("de.jensklingenberg.ktorfit:ktorfit-converters-call:$ktorfitVersion")
implementation("de.jensklingenberg.ktorfit:ktorfit-converters-flow:$ktorfitVersion")
implementation("de.jensklingenberg.ktorfit:ktorfit-converters-response-ktor-3.0.0-beta-2:$ktorfitVersion")
implementation("de.jensklingenberg.ktorfit:ktorfit-converters-call-ktor-3.0.0-beta-2:$ktorfitVersion")
implementation("de.jensklingenberg.ktorfit:ktorfit-converters-flow-ktor-3.0.0-beta-2:$ktorfitVersion")

//Only needed when you want to use Kotlin Serialization
// Only needed when you want to use Kotlin Serialization
implementation("io.ktor:ktor-client-serialization:$ktorVersion")
implementation("io.ktor:ktor-client-content-negotiation:$ktorVersion")
implementation("io.ktor:ktor-serialization-kotlinx-json:$ktorVersion")
Expand All @@ -75,17 +75,16 @@ android {
compileSdk = 34
sourceSets["main"].manifest.srcFile("src/androidMain/AndroidManifest.xml")
defaultConfig {
namespace = "com.example.myapplication.shared"
minSdk = 21
targetSdk = 34
}
compileOptions {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
}

}


tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile> {
kotlinOptions {
jvmTarget = "1.8"
Expand All @@ -99,4 +98,4 @@ allprojects {
url = uri("https://oss.sonatype.org/content/repositories/snapshots/")
}
}
}
}
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest package="com.example.ktorfittest"/>
<manifest />

0 comments on commit d2e2142

Please sign in to comment.