Commit 399dfb3
authored
Cleanup (#1045)
* Update to Kotlin 2.3.20-RC3
* Add a convention plugin for KMP
* Add a jvm convention plugin
* Update Gradle to 9.4.0
* Update kctfork
* Clean up version catalog, consolidate versions, remove deprecated properties
- Rename `abg` to `agp`, remove duplicate `gradleMavenPublishPlugin` version
- Consolidate 8 ktorfit version entries to 3 (ktorfit, ktorfitCompiler, ktorfitGradlePlugin)
- Remove `groupId` from catalog, use `group` property in gradle.properties instead
- Add ktlint, gradlePluginPublish, licensee plugin entries to catalog
- Remove platform-specific ktor-client-core-* and ktor-client-cio-* catalog entries
- Replace platform-specific ktor deps with common artifacts in ktorfit-lib and sandbox
- Remove stale `kotlinx-serialization-runtime-js` usage from sandbox
- Remove deprecated `kotlin.native.binary.freezing` from root gradle.properties
- Remove deprecated `kotlin.mpp.androidSourceSetLayoutVersion=2` from module gradle.properties
- Add POM_ARTIFACT_ID to all module gradle.properties for vanniktech publishing
- Add `kotlin.js.yarn=false` to gradle.properties (Phase 10 prep)
- Update AGP to 9.0.0 and Detekt to 2.0.0-alpha.2 in catalog (Phases 4+8 prep)
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* Add publishing convention plugin and remove per-module publishing boilerplate
Create `ktorfit.publishing` convention plugin using vanniktech maven-publish
that handles publishToMavenCentral, signAllPublications, and all POM metadata
automatically from gradle.properties.
This removes from every module:
- `maven-publish` and `signing` plugin applications
- `enableSigning` conditional logic and sign task dependency workaround
- `javadocJar` task registration (vanniktech handles this)
- Entire `publishing { publications { ... } }` POM blocks (~30 lines each)
- Entire `publishing { repositories { ... } }` sonatype blocks (~15 lines each)
Each module now just applies `id("ktorfit.publishing")` and calls
`mavenPublishing { coordinates(version = ...) }`.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* Add licensee convention plugin to deduplicate license config
Create `ktorfit.licensee` convention plugin that applies licensee and
configures Apache-2.0, MIT, and MIT URL allowances. Replace per-module
licensee blocks in all 8 published modules.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* Remove buildscript block and clean up repository configuration
- Remove entire buildscript block from root build.gradle.kts (classpath deps
now handled by build-logic convention plugins)
- Remove mavenLocal() from settings.gradle.kts and build-logic settings
- Remove duplicate google() repository
- Remove Ktor EAP and Kotlin WASM experimental repos (not needed)
- Remove resolutionStrategy for de.jensklingenberg.ktorfit plugin
- Move pluginManagement.dependencyResolutionManagement to top-level
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* Migrate to AGP 9 KMP plugin and Detekt v2
AGP 9 migration:
- Replace `com.android.library` with `com.android.kotlin.multiplatform.library`
in KMP convention plugin
- Move `androidTarget { publishLibraryVariants() }` to `androidLibrary {}`
- Remove standalone `android {}` blocks from all modules; move namespace
into `kotlin { androidLibrary { namespace = "..." } }`
- Update compileSdk to 35, remove manual manifest srcFile setup
- Remove consumerProguardFiles from ktorfit-lib-core (not supported in
AGP 9 KMP library plugin)
Detekt v2 migration:
- Update plugin ID from `io.gitlab.arturbosch.detekt` to `dev.detekt`
- Update Maven group from `io.gitlab.arturbosch.detekt` to `dev.detekt`
- Create `ktorfit.detekt` convention plugin with shared config
- Replace per-module detekt configuration blocks
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* Switch from Yarn to npm for JS/WASM targets
- Set kotlin.js.yarn=false in gradle.properties (done in earlier commit)
- Remove kotlin-js-store/ directory containing yarn.lock files
- npm lock files will be generated on next build via kotlinUpgradePackageLock
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* Move CI to ubuntu-latest and centralize Java version in .java-version
- Create .java-version file (JDK 25)
- Move build job from macos-latest to ubuntu-latest (klib cross-compilation)
- Move publish-annotations and publish-ktorfit-lib from macos-latest to ubuntu-latest
- Move publish-converters from macos-latest to ubuntu-latest
- Replace hardcoded java-version: 21 with java-version-file: .java-version
across all workflow jobs
- Remove manual Gradle cache setup (gradle/actions/setup-gradle handles it)
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* Consolidate dependabot into renovate
- Remove .github/dependabot.yml (renovate handles gradle + github-actions)
- Remove update-gradle-wrapper.yml workflow (renovate handles wrapper updates)
- Update renovate.json5 with enabledManagers for gradle, gradle-wrapper,
and github-actions; add registryUrls and dependency labels
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* Remove unused catalog entries and add serialization plugin to root
- Remove unused `kotlin-serialization` library (was in removed buildscript block)
- Remove unused `ktorfit-gradle-plugin` library (sandbox uses project substitution)
- Add `kotlin("plugin.serialization")` to root plugins block so sandbox can
resolve `id("kotlinx-serialization")` without buildscript classpath
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* Fix build issues from modernization
- Change build-logic deps from compileOnly to implementation (required for
precompiled script plugins to resolve plugin IDs at apply time)
- Re-add buildscript classpath for ktorfit-gradle-plugin (needed by sandbox)
- Re-add resolutionStrategy for de.jensklingenberg.ktorfit plugin in settings
- Update sandbox to use alias(libs.plugins.licensee) and alias(libs.plugins.ktorfit)
- Update detekt-config.yml for v2: rename ComplexMethod to
CyclomaticComplexMethod, remove removed rules, fix excludedFunctions YAML format
- Regenerate detekt baselines for compiler-plugin and ksp modules
- Remove obsolete supportsK2 from compiler-plugin test (K2 is now default)
- Fix ktlint trailing blank line in compiler-plugin build file
- Regenerate klib API dumps (library unique name changed due to group property)
- Use released ktorfitGradlePlugin version (2.7.2) for buildscript resolution
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* Add npm lock files after yarn-to-npm migration
Generated by the build after setting kotlin.js.yarn=false.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* Use GROUP instead of group in gradle.properties to preserve klib API
The lowercase `group` property sets Gradle's project group, which changes
the klib library unique name (e.g. <Ktorfit:ktorfit-annotations> becomes
<de.jensklingenberg.ktorfit:ktorfit-annotations>). Use uppercase `GROUP`
instead, which the vanniktech maven-publish plugin reads for publishing
coordinates without affecting the project group.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* Fix quick-win Kotlin warnings and add warnings plan doc
Suppress unnecessary safe call warnings on KSType in KSP code generators,
add @Suppress("UNCHECKED_CAST") for intentional generic casts, fix parameter
name mismatch in test, and remove deprecated developmentMode usage in sandbox.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* Update AGP to 9.1.0
* Update maven publish plugin
* Cleanup gradle plugin module
* Update gradle plugin publish
* Add comment explaining the ktorfit versions in the catalog
* Update mockk
* Remove kapt
* Update releasing instructions
* Publish SNAPSHOT builds on pushes to master
* Fix more warnings
* Clean up sandbox build.gradle.kts
* Handle deprecated API
* Update Gradle checksum
* Don't require signing when publishing to maven local
* Simplify running tasks on all modules in GitHub Actions
* Add test for #887
* Silence licensee unused license warning
* Don't apply kotlin(jvm) and kotlin-dsl plugins together
* Make detekt quieter when there are no violations1 parent 6f204c2 commit 399dfb3
75 files changed
Lines changed: 2051 additions & 2213 deletions
File tree
- .github
- workflows
- build-logic
- src/main/kotlin
- gradle
- wrapper
- kotlin-js-store
- wasm
- ktorfit-annotations
- api
- ktorfit-compiler-plugin
- src
- main/java/de/jensklingenberg/ktorfit
- test/kotlin/de/jensklingenberg/ktorfit
- ktorfit-converters
- call
- api
- src/jvmTest/kotlin
- flow
- api
- response
- api
- ktorfit-gradle-plugin
- ktorfit-ksp
- src/main/kotlin/de/jensklingenberg/ktorfit
- reqBuilderExtension
- utils
- ktorfit-lib-core
- api
- src
- commonMain/kotlin/de/jensklingenberg/ktorfit
- converter
- internal
- commonTest/kotlin/de/jensklingenberg/ktorfit
- internal
- jvmTest/kotlin/de/jensklingenberg/ktorfit
- converter
- internal
- ktorfit-lib
- api
- sandbox
- src
- commonMain/kotlin/com/example/api
- jsMain/kotlin
- jvmMain/kotlin/de/jensklingenberg/ktorfit/demo
- linuxMain/kotlin
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
This file was deleted.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
24 | | - | |
| 24 | + | |
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
| |||
56 | 56 | | |
57 | 57 | | |
58 | 58 | | |
59 | | - | |
| 59 | + | |
60 | 60 | | |
61 | 61 | | |
62 | 62 | | |
| |||
73 | 73 | | |
74 | 74 | | |
75 | 75 | | |
76 | | - | |
| 76 | + | |
77 | 77 | | |
78 | 78 | | |
79 | 79 | | |
80 | 80 | | |
81 | 81 | | |
82 | 82 | | |
83 | 83 | | |
84 | | - | |
| 84 | + | |
85 | 85 | | |
86 | 86 | | |
87 | | - | |
| 87 | + | |
88 | 88 | | |
89 | 89 | | |
90 | | - | |
91 | 90 | | |
92 | | - | |
93 | | - | |
94 | | - | |
95 | | - | |
96 | | - | |
97 | | - | |
98 | | - | |
99 | | - | |
100 | | - | |
101 | | - | |
102 | | - | |
| 91 | + | |
| 92 | + | |
103 | 93 | | |
104 | | - | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
| 8 | + | |
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
13 | | - | |
| 13 | + | |
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
17 | | - | |
| 17 | + | |
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
12 | | - | |
| 12 | + | |
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
16 | | - | |
| 16 | + | |
17 | 17 | | |
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
23 | | - | |
| 23 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
| 8 | + | |
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
13 | | - | |
| 13 | + | |
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
17 | | - | |
| 17 | + | |
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
| |||
31 | 31 | | |
32 | 32 | | |
33 | 33 | | |
34 | | - | |
| 34 | + | |
35 | 35 | | |
36 | 36 | | |
37 | 37 | | |
38 | | - | |
| 38 | + | |
39 | 39 | | |
40 | 40 | | |
41 | 41 | | |
| |||
52 | 52 | | |
53 | 53 | | |
54 | 54 | | |
55 | | - | |
| 55 | + | |
56 | 56 | | |
57 | 57 | | |
58 | 58 | | |
59 | | - | |
| 59 | + | |
60 | 60 | | |
61 | 61 | | |
62 | 62 | | |
| |||
73 | 73 | | |
74 | 74 | | |
75 | 75 | | |
76 | | - | |
| 76 | + | |
77 | 77 | | |
78 | 78 | | |
79 | 79 | | |
80 | | - | |
| 80 | + | |
81 | 81 | | |
82 | 82 | | |
83 | 83 | | |
| |||
89 | 89 | | |
90 | 90 | | |
91 | 91 | | |
92 | | - | |
| 92 | + | |
93 | 93 | | |
94 | 94 | | |
95 | 95 | | |
96 | 96 | | |
97 | | - | |
| 97 | + | |
98 | 98 | | |
99 | 99 | | |
100 | 100 | | |
101 | | - | |
| 101 | + | |
102 | 102 | | |
103 | 103 | | |
104 | 104 | | |
| |||
This file was deleted.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
7 | | - | |
8 | | - | |
9 | | - | |
10 | | - | |
11 | | - | |
12 | | - | |
13 | | - | |
14 | | - | |
15 | | - | |
16 | | - | |
17 | | - | |
18 | | - | |
19 | | - | |
20 | | - | |
21 | | - | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
0 commit comments