Skip to content

Commit

Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Release 2.0.0
Browse files Browse the repository at this point in the history
Foso committed May 27, 2024

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
1 parent 274b4eb commit 8417cc8
Showing 9 changed files with 30 additions and 47 deletions.
2 changes: 1 addition & 1 deletion docs/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -7,7 +7,7 @@ and this project orients towards [Semantic Versioning](http://semver.org/spec/v2
Note: This project needs KSP to work and every new Ktorfit with an update of the KSP version is technically a breaking change.
But there is no intent to bump the Ktorfit major version for every KSP update.

2.0.0 - 2024-XX-XX
2.0.0 - 2024-05-27
========================================
### Changed
- Build with KSP 1.0.21, Kotlin 2.0.0, Ktor 2.3.11
14 changes: 6 additions & 8 deletions example/AndroidOnlyExample/app/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
plugins {
id("com.android.application")
id("org.jetbrains.kotlin.android")
id("com.google.devtools.ksp") version "1.9.23-1.0.20"
id("org.jetbrains.kotlin.plugin.serialization") version "1.9.23"
id("de.jensklingenberg.ktorfit") version "2.0.0-beta2-SNAPSHOT"
id("com.google.devtools.ksp") version "2.0.0-1.0.21"
id("org.jetbrains.kotlin.plugin.serialization") version "2.0.0"
id("de.jensklingenberg.ktorfit") version "2.0.0"
id("org.jetbrains.kotlin.plugin.compose") version "2.0.0"

}


@@ -40,9 +42,6 @@ android {
buildFeatures {
compose = (true)
}
composeOptions {
kotlinCompilerExtensionVersion = "1.5.11"
}
}

tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile>().configureEach {
@@ -51,11 +50,10 @@ tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile>().configureEach
}
}

val ktorfit = "2.0.0-beta2-SNAPSHOT"
val ktorfit = "2.0.0"
val ktor = "2.3.10"
val compose_ui_version = "1.5.1"
dependencies {
ksp("de.jensklingenberg.ktorfit:ktorfit-ksp:$ktorfit")
implementation("de.jensklingenberg.ktorfit:ktorfit-lib:$ktorfit")
implementation("io.ktor:ktor-client-serialization:$ktor")
implementation("io.ktor:ktor-client-content-negotiation:$ktor")
Original file line number Diff line number Diff line change
@@ -35,6 +35,7 @@ val ktorfit = ktorfit {
)

}
val api = ktorfit.createStarWarsApi()

class MainActivity : ComponentActivity() {

@@ -57,8 +58,9 @@ class MainActivity : ComponentActivity() {
}
}


lifecycleScope.launch {
peopleState.value = ktorfit.create<StarWarsApi>().getPerson(1)
peopleState.value = api.getPerson(1)
}
}
}
2 changes: 1 addition & 1 deletion example/AndroidOnlyExample/build.gradle
Original file line number Diff line number Diff line change
@@ -2,5 +2,5 @@
plugins {
id 'com.android.application' version '8.0.2' apply false
id 'com.android.library' version '8.0.2' apply false
id 'org.jetbrains.kotlin.android' version '1.9.23' apply false
id 'org.jetbrains.kotlin.android' version '2.0.0' apply false
}
27 changes: 6 additions & 21 deletions example/MultiplatformExample/shared/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -6,13 +6,17 @@ plugins {
id("com.android.library")
id("com.google.devtools.ksp") version "2.0.0-1.0.21"
id("kotlinx-serialization")
id("de.jensklingenberg.ktorfit") version "2.0.0-SNAPSHOT"
id("de.jensklingenberg.ktorfit") version "2.0.0"
}

ktorfit {
errorCheckingMode = ErrorCheckingMode.WARNING
generateQualifiedTypeName = false
}

version = "1.0"
val ktorVersion = "2.3.10"
val ktorfitVersion = "2.0.0-beta2-SNAPSHOT"
val ktorfitVersion = "2.0.0"

kotlin {
jvmToolchain(8)
@@ -76,25 +80,6 @@ android {
}
}

dependencies {
with("de.jensklingenberg.ktorfit:ktorfit-ksp:$ktorfitVersion") {
add("kspCommonMainMetadata", this)
add("kspJvm", this)
add("kspJvmTest", this)
add("kspAndroid", this)
add("kspAndroidTest", this)
add("kspIosX64", this)
add("kspIosX64Test", this)
add("kspIosArm64", this)
add("kspIosArm64Test", this)
add("kspIosSimulatorArm64", this)
add("kspIosSimulatorArm64Test", this)
add("kspMacosX64", this)
add("kspMacosX64Test", this)
add("kspJs", this)
add("kspJsTest", this)
}
}

tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile> {
kotlinOptions {
Original file line number Diff line number Diff line change
@@ -4,9 +4,9 @@ package com.example.ktorfittest
import de.jensklingenberg.ktorfit.converter.CallConverterFactory
import de.jensklingenberg.ktorfit.converter.FlowConverterFactory
import de.jensklingenberg.ktorfit.ktorfit
import io.ktor.client.HttpClient
import io.ktor.client.plugins.contentnegotiation.ContentNegotiation
import io.ktor.serialization.kotlinx.json.json
import io.ktor.client.*
import io.ktor.client.plugins.contentnegotiation.*
import io.ktor.serialization.kotlinx.json.*
import kotlinx.coroutines.DelicateCoroutinesApi
import kotlinx.coroutines.GlobalScope
import kotlinx.coroutines.launch
@@ -26,7 +26,7 @@ val ktorfit = ktorfit {
}


val starWarsApi = ktorfit.create<StarWarsApi>()
val starWarsApi = ktorfit.createStarWarsApi()

class Greeting {
fun greeting(): String {
14 changes: 7 additions & 7 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
@@ -10,13 +10,13 @@ kotlin = "2.0.0"
kotlinPoet = "1.16.0"
kspVersion = "2.0.0-1.0.21"

ktorfit = "2.0.0-SNAPSHOT"
ktorfitKsp = "2.0.0-1.0.21-SNAPSHOT"
ktorfitCompiler = "2.0.0-2.0.0-SNAPSHOT"
ktorfitCallConverter = "2.0.0-SNAPSHOT"
ktorfitFlowConverter = "2.0.0-SNAPSHOT"
ktorfitResponseConverter = "2.0.0-SNAPSHOT"
ktorfitGradle = "2.0.0-SNAPSHOT"
ktorfit = "2.0.0"
ktorfitKsp = "2.0.0-1.0.21"
ktorfitCompiler = "2.0.0-2.0.0"
ktorfitCallConverter = "2.0.0"
ktorfitFlowConverter = "2.0.0"
ktorfitResponseConverter = "2.0.0"
ktorfitGradle = "2.0.0"

ktorfitGradlePlugin = "1.14.0"
ktorVersion = "2.3.11"
Original file line number Diff line number Diff line change
@@ -3,9 +3,7 @@ package de.jensklingenberg.ktorfit.gradle
import org.gradle.api.Plugin
import org.gradle.api.Project
import org.gradle.kotlin.dsl.dependencies
import org.gradle.kotlin.dsl.findByType
import org.jetbrains.kotlin.gradle.dsl.KotlinMultiplatformExtension
import org.jetbrains.kotlin.gradle.dsl.KotlinProjectExtension
import org.jetbrains.kotlin.gradle.dsl.KotlinSingleTargetExtension
import org.jetbrains.kotlin.gradle.dsl.kotlinExtension
import org.jetbrains.kotlin.gradle.tasks.KotlinCompilationTask
@@ -18,7 +16,7 @@ class KtorfitGradlePlugin : Plugin<Project> {
const val ARTIFACT_NAME = "compiler-plugin"
const val COMPILER_PLUGIN_ID = "ktorfitPlugin"
const val KTORFIT_VERSION = "2.0.0" // remember to bump this version before any release!
const val SNAPSHOT = "-SNAPSHOT"
const val SNAPSHOT = ""
const val MIN_KSP_VERSION = "1.0.21"
const val MIN_KOTLIN_VERSION = "2.0.0"
}
2 changes: 1 addition & 1 deletion mkdocs.yml
Original file line number Diff line number Diff line change
@@ -13,7 +13,7 @@ extra:
site:
images: '../../images'
ktorfit:
release: "2.0.0-rc01"
release: "2.0.0"
ktor:
release: "2.3.11"
social:

0 comments on commit 8417cc8

Please sign in to comment.