From 8e51a1d36ea5c812f278a74873b5763a3aeca81e Mon Sep 17 00:00:00 2001 From: Jens Klingenberg Date: Sun, 28 Apr 2024 20:19:29 +0200 Subject: [PATCH] Release 2.0.0-beta1 (#543) --- README.md | 10 +++++----- docs/CHANGELOG.md | 2 +- docs/index.md | 19 ++++++++++--------- .../AndroidOnlyExample/app/build.gradle.kts | 4 ++-- .../androidonlyexample/MainActivity.kt | 7 +++---- .../shared/build.gradle.kts | 7 +++++-- .../com/example/ktorfittest/Greeting.kt | 5 +++-- gradle/libs.versions.toml | 2 +- .../gradle/KtorfitCompilerSubPlugin.kt | 2 +- mkdocs.yml | 2 +- 10 files changed, 32 insertions(+), 28 deletions(-) diff --git a/README.md b/README.md index 8fbc0184a..92ae617aa 100644 --- a/README.md +++ b/README.md @@ -32,7 +32,7 @@ build.gradle.kts: ```kotlin plugins { - id("de.jensklingenberg.ktorfit") version "1.14.0" + id("de.jensklingenberg.ktorfit") version "2.0.0-beta1" } ``` @@ -40,22 +40,22 @@ build.gradle ```kotlin plugins { - id("de.jensklingenberg.ktorfit") version "1.14.0" + id("de.jensklingenberg.ktorfit") version "2.0.0-beta1" } ``` KSP: ```kotlin -de.jensklingenberg.ktorfit:ktorfit-ksp:1.14.0 +de.jensklingenberg.ktorfit:ktorfit-ksp:2.0.0-beta1 ``` Ktorfit-lib/-light: ```kotlin -implementation("de.jensklingenberg.ktorfit:ktorfit-lib:1.14.0") +implementation("de.jensklingenberg.ktorfit:ktorfit-lib:2.0.0-beta1") or -implementation("de.jensklingenberg.ktorfit:ktorfit-lib-light:1.14.0") +implementation("de.jensklingenberg.ktorfit:ktorfit-lib-light:2.0.0-beta1") ``` ## 👷 Project Structure diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 89e3c336a..72e7a8fc5 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -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-beta1 - Unreleased +2.0.0-beta1 - 2024-04-28 ======================================== ### Breaking Changes diff --git a/docs/index.md b/docs/index.md index f8d96ac99..150b6164b 100644 --- a/docs/index.md +++ b/docs/index.md @@ -15,15 +15,16 @@ inspired by [Retrofit](https://square.github.io/retrofit/) ## Compatibility -| Ktorfit-version | Kotlin | KSP | Ktor | -|--------------------------|:-------------------------:|:-----------------------:|:----------:| -| **_1.14.0_** | **2.0.0-RC1** | **1.0.20** | **2.3.10** | -| **_1.13.0_** | **1.9.23** | **1.0.20** | **2.3.10** | -| **_1.12.0_** | **1.9.22** | **1.0.16** | **2.3.6** | -| **_1.11.0_** | **1.9.21** | **1.0.15** | **2.3.6** | -| **_1.10.2_** | **1.9.20** | **1.0.14** | **2.3.6** | -| **_1.10.1_** | **1.9.20** | **1.0.14** | **2.3.4** | -| **_1.10.0_** | **1.9.20** | **1.0.14** | **2.3.4** | +| Ktorfit-version | Kotlin | KSP | Ktor | +|-------------------|:-------------:|:----------:|:----------:| +| **_2.0.0-beta1_** | **2.0.0-RC1** | **1.0.20** | **2.3.10** | +| **_1.14.0_** | **2.0.0-RC1** | **1.0.20** | **2.3.10** | +| **_1.13.0_** | **1.9.23** | **1.0.20** | **2.3.10** | +| **_1.12.0_** | **1.9.22** | **1.0.16** | **2.3.6** | +| **_1.11.0_** | **1.9.21** | **1.0.15** | **2.3.6** | +| **_1.10.2_** | **1.9.20** | **1.0.14** | **2.3.6** | +| **_1.10.1_** | **1.9.20** | **1.0.14** | **2.3.4** | +| **_1.10.0_** | **1.9.20** | **1.0.14** | **2.3.4** | # Installation diff --git a/example/AndroidOnlyExample/app/build.gradle.kts b/example/AndroidOnlyExample/app/build.gradle.kts index cf3d2a95b..df33f49e9 100644 --- a/example/AndroidOnlyExample/app/build.gradle.kts +++ b/example/AndroidOnlyExample/app/build.gradle.kts @@ -3,7 +3,7 @@ plugins { 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-beta1-SNAPSHOT" + id("de.jensklingenberg.ktorfit") version "2.0.0-beta1" } @@ -51,7 +51,7 @@ tasks.withType().configureEach } } -val ktorfit = "2.0.0-beta1-SNAPSHOT" +val ktorfit = "2.0.0-beta1" val ktor = "2.3.10" val compose_ui_version = "1.5.1" dependencies { diff --git a/example/AndroidOnlyExample/app/src/main/java/de/jensklingenberg/androidonlyexample/MainActivity.kt b/example/AndroidOnlyExample/app/src/main/java/de/jensklingenberg/androidonlyexample/MainActivity.kt index e2f9a9055..3c9696520 100644 --- a/example/AndroidOnlyExample/app/src/main/java/de/jensklingenberg/androidonlyexample/MainActivity.kt +++ b/example/AndroidOnlyExample/app/src/main/java/de/jensklingenberg/androidonlyexample/MainActivity.kt @@ -1,7 +1,6 @@ package de.jensklingenberg.androidonlyexample import android.os.Bundle -import android.util.Log import androidx.activity.ComponentActivity import androidx.activity.compose.setContent import androidx.compose.foundation.layout.fillMaxSize @@ -12,9 +11,9 @@ import androidx.compose.runtime.mutableStateOf import androidx.compose.ui.Modifier import androidx.lifecycle.lifecycleScope import de.jensklingenberg.androidonlyexample.ui.theme.AndroidOnlyExampleTheme -import de.jensklingenberg.ktorfit.converter.builtin.CallConverterFactory -import de.jensklingenberg.ktorfit.converter.builtin.FlowConverterFactory -import de.jensklingenberg.ktorfit.converter.builtin.ResponseConverterFactory +import de.jensklingenberg.ktorfit.converter.CallConverterFactory +import de.jensklingenberg.ktorfit.converter.FlowConverterFactory +import de.jensklingenberg.ktorfit.converter.ResponseConverterFactory import de.jensklingenberg.ktorfit.ktorfit import io.ktor.client.HttpClient import io.ktor.client.plugins.contentnegotiation.ContentNegotiation diff --git a/example/MultiplatformExample/shared/build.gradle.kts b/example/MultiplatformExample/shared/build.gradle.kts index ddbcf4c0a..b39d7a1ad 100644 --- a/example/MultiplatformExample/shared/build.gradle.kts +++ b/example/MultiplatformExample/shared/build.gradle.kts @@ -4,12 +4,12 @@ plugins { id("com.android.library") id("com.google.devtools.ksp") version "1.9.23-1.0.20" id("kotlinx-serialization") - id("de.jensklingenberg.ktorfit") version "1.14.0" + id("de.jensklingenberg.ktorfit") version "2.0.0-beta1" } version = "1.0" val ktorVersion = "2.3.10" -val ktorfitVersion = "1.14.0" +val ktorfitVersion = "2.0.0-beta1" kotlin { jvmToolchain(8) @@ -41,6 +41,9 @@ kotlin { implementation("de.jensklingenberg.ktorfit:ktorfit-lib:$ktorfitVersion") //implementation("de.jensklingenberg.ktorfit:ktorfit-lib-light:$ktorfitVersion") implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:1.8.0") + implementation("de.jensklingenberg.ktorfit:ktorfit-converters-response:$ktorfitVersion") + implementation("de.jensklingenberg.ktorfit:ktorfit-converters-call:$ktorfitVersion") + implementation("de.jensklingenberg.ktorfit:ktorfit-converters-flow:$ktorfitVersion") //Only needed when you want to use Kotlin Serialization implementation("io.ktor:ktor-client-serialization:$ktorVersion") diff --git a/example/MultiplatformExample/shared/src/commonMain/kotlin/com/example/ktorfittest/Greeting.kt b/example/MultiplatformExample/shared/src/commonMain/kotlin/com/example/ktorfittest/Greeting.kt index 953f94724..799cc6413 100644 --- a/example/MultiplatformExample/shared/src/commonMain/kotlin/com/example/ktorfittest/Greeting.kt +++ b/example/MultiplatformExample/shared/src/commonMain/kotlin/com/example/ktorfittest/Greeting.kt @@ -1,7 +1,8 @@ package com.example.ktorfittest -import de.jensklingenberg.ktorfit.converter.builtin.CallConverterFactory -import de.jensklingenberg.ktorfit.converter.builtin.FlowConverterFactory + +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 diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 231e32481..497f89dda 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -9,7 +9,7 @@ kctfork = "0.4.1" kotlin = "2.0.0-RC1" kotlinPoet = "1.16.0" kspVersion = "2.0.0-RC1-1.0.20" -ktorfit = "2.0.0-beta1-SNAPSHOT" +ktorfit = "2.0.0-beta1" ktorfitGradlePlugin = "1.14.0" ktorVersion = "2.3.10" mockk = "1.13.8" diff --git a/ktorfit-gradle-plugin/src/main/java/de/jensklingenberg/ktorfit/gradle/KtorfitCompilerSubPlugin.kt b/ktorfit-gradle-plugin/src/main/java/de/jensklingenberg/ktorfit/gradle/KtorfitCompilerSubPlugin.kt index 8dd66b1dd..4bfadf890 100644 --- a/ktorfit-gradle-plugin/src/main/java/de/jensklingenberg/ktorfit/gradle/KtorfitCompilerSubPlugin.kt +++ b/ktorfit-gradle-plugin/src/main/java/de/jensklingenberg/ktorfit/gradle/KtorfitCompilerSubPlugin.kt @@ -47,7 +47,7 @@ internal class KtorfitCompilerSubPlugin : KotlinCompilerPluginSupportPlugin { return SubpluginArtifact( groupId = SERIALIZATION_GROUP_NAME, artifactId = ARTIFACT_NAME, - version = "2.0.0-beta1-SNAPSHOT" // remember to bump this version before any release! + version = "2.0.0-beta1" // remember to bump this version before any release! ) } } diff --git a/mkdocs.yml b/mkdocs.yml index 8691cd8e9..8a372abbd 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -13,7 +13,7 @@ extra: site: images: '../../images' ktorfit: - release: "1.14.0" + release: "2.0.0-beta1" ktor: release: "2.3.10" social: