Skip to content

Commit 65762b2

Browse files
Merge pull request #3 from caplin/dependency-updates
Build: Update Spring Boot, Gradle & DataSource. Replace Ktfmt plugin with Spotless.
2 parents 3c496d2 + 0dfc41b commit 65762b2

File tree

47 files changed

+293
-969
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

47 files changed

+293
-969
lines changed

.idea/AndroidProjectSystem.xml

Lines changed: 6 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/DataSource-Extensions.iml

Lines changed: 9 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/kotlinc.xml

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/misc.xml

Lines changed: 0 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

build.gradle.kts

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,16 @@
11
plugins {
22
id("org.jetbrains.kotlinx.kover")
3+
id("com.diffplug.spotless")
34
base
45
}
56

7+
spotless {
8+
kotlinGradle {
9+
ktfmt(libs.versions.ktfmt.get())
10+
target("*.gradle.kts")
11+
}
12+
}
13+
614
dependencies {
715
kover(project(":reactive:datasourcex-reactive-api"))
816
kover(project(":reactive:datasourcex-reactive-core"))
@@ -13,12 +21,4 @@ dependencies {
1321
kover(project(":datasourcex-util"))
1422
}
1523

16-
kover {
17-
reports {
18-
filters {
19-
excludes {
20-
packages("samples")
21-
}
22-
}
23-
}
24-
}
24+
kover { reports { filters { excludes { packages("samples") } } } }

buildSrc/build.gradle.kts

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,25 @@
11
plugins {
22
`kotlin-dsl`
3-
id("com.ncorti.ktfmt.gradle") version libs.versions.ktfmt.plugin
3+
id("com.diffplug.spotless") version libs.versions.spotless.plugin
4+
}
5+
6+
kotlin {
7+
jvmToolchain(17)
48
}
59

610
dependencies {
711
implementation(libs.kotlinpoet)
812

9-
implementation(libs.ktfmt.plugin)
13+
implementation(libs.spotless.plugin)
1014
implementation(libs.dokka.plugin)
11-
implementation(libs.detekt.plugin)
1215
implementation(libs.binary.compatibility.validator.plugin)
1316
implementation(libs.kover.plugin)
1417
implementation(libs.kotlin.plugin)
1518
implementation(libs.kotlin.allopen.plugin)
1619
implementation(libs.vanniktech.maven.publish.plugin)
1720
}
21+
22+
spotless {
23+
kotlinGradle { ktfmt(libs.versions.ktfmt.get()) }
24+
kotlin { ktfmt(libs.versions.ktfmt.get()) }
25+
}

buildSrc/src/main/kotlin/common-library.gradle.kts

Lines changed: 17 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1+
12
import com.vanniktech.maven.publish.JavadocJar
23
import com.vanniktech.maven.publish.KotlinJvm
3-
import org.gradle.api.JavaVersion.VERSION_17
44
import org.gradle.api.file.DuplicatesStrategy.WARN
55

66
plugins {
@@ -10,14 +10,26 @@ plugins {
1010
idea
1111
id("org.jetbrains.kotlinx.kover")
1212
id("org.jetbrains.kotlinx.binary-compatibility-validator")
13-
id("com.ncorti.ktfmt.gradle")
14-
id("io.gitlab.arturbosch.detekt")
13+
id("com.diffplug.spotless")
1514
id("org.jetbrains.dokka")
1615
}
1716

17+
val libs = extensions.getByType<VersionCatalogsExtension>().named("libs")
18+
val ktfmtVersion = libs.findVersion("ktfmt").get().requiredVersion
19+
20+
spotless {
21+
kotlin {
22+
ktfmt(ktfmtVersion)
23+
target("src/**/*.kt")
24+
}
25+
kotlinGradle {
26+
ktfmt(ktfmtVersion)
27+
target("*.gradle.kts")
28+
}
29+
}
30+
1831
java {
19-
sourceCompatibility = VERSION_17
20-
targetCompatibility = VERSION_17
32+
toolchain { languageVersion.set(JavaLanguageVersion.of(17)) }
2133
withSourcesJar()
2234
}
2335

0 commit comments

Comments
 (0)