Skip to content

Commit e18847c

Browse files
committed
Update to the latest config.
1 parent 4e77865 commit e18847c

34 files changed

+332
-98
lines changed

.idea/dictionaries/common.xml

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

.idea/inspectionProfiles/Project_Default.xml

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

.lift.toml

Lines changed: 0 additions & 1 deletion
This file was deleted.

buildSrc/build.gradle.kts

Lines changed: 55 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,12 @@ plugins {
3434
java
3535
groovy
3636
`kotlin-dsl`
37-
val licenseReportVersion = "2.1"
38-
id("com.github.jk1.dependency-license-report").version(licenseReportVersion)
37+
38+
// https://github.com/jk1/Gradle-License-Report/releases
39+
id("com.github.jk1.dependency-license-report").version("2.1")
40+
41+
// https://github.com/johnrengelman/shadow/releases
42+
id("com.github.johnrengelman.shadow").version("7.1.2")
3943
}
4044

4145
repositories {
@@ -50,17 +54,27 @@ repositories {
5054
* Please keep this value in sync. with `io.spine.internal.dependency.Jackson.version`.
5155
* It's not a requirement, but would be good in terms of consistency.
5256
*/
53-
val jacksonVersion = "2.13.4"
57+
val jacksonVersion = "2.15.3"
58+
59+
/**
60+
* The version of Google Artifact Registry used by `buildSrc`.
61+
*
62+
* The version `2.1.5` is the latest before `2.2.0`, which introduces breaking changes.
63+
*
64+
* @see <a href="https://mvnrepository.com/artifact/com.google.cloud.artifactregistry/artifactregistry-auth-common">
65+
* Google Artifact Registry at Maven</a>
66+
*/
67+
val googleAuthToolVersion = "2.1.5"
5468

55-
val googleAuthToolVersion = "2.1.2"
5669
val licenseReportVersion = "2.1"
70+
5771
val grGitVersion = "4.1.1"
5872

5973
/**
60-
* The version of the Kotlin Gradle plugin.
74+
* The version of the Kotlin Gradle plugin and Kotlin binaries used by the build process.
6175
*
62-
* Please check that this value matches one defined in
63-
* [io.spine.internal.dependency.Kotlin.version].
76+
* This version may change from the [version of Kotlin][io.spine.internal.dependency.Kotlin.version]
77+
* used by the project.
6478
*/
6579
val kotlinVersion = "1.8.22"
6680

@@ -70,7 +84,7 @@ val kotlinVersion = "1.8.22"
7084
* Always use the same version as the one specified in [io.spine.internal.dependency.Guava].
7185
* Otherwise, when testing Gradle plugins, clashes may occur.
7286
*/
73-
val guavaVersion = "32.1.2-jre"
87+
val guavaVersion = "32.1.3-jre"
7488

7589
/**
7690
* The version of ErrorProne Gradle plugin.
@@ -100,7 +114,7 @@ val protobufPluginVersion = "0.9.4"
100114
* @see <a href="https://github.com/Kotlin/dokka/releases">
101115
* Dokka Releases</a>
102116
*/
103-
val dokkaVersion = "1.8.10"
117+
val dokkaVersion = "1.9.10"
104118

105119
/**
106120
* The version of Detekt Gradle Plugin.
@@ -119,11 +133,19 @@ val kotestJvmPluginVersion = "0.4.10"
119133
*/
120134
val koverVersion = "0.7.2"
121135

136+
/**
137+
* The version of the Shadow Plugin.
138+
*
139+
* `7.1.2` is the last version compatible with Gradle 7.x. Newer versions require Gradle v8.x.
140+
*
141+
* @see <a href="https://github.com/johnrengelman/shadow/releases">Shadow Plugin releases</a>
142+
*/
143+
val shadowVersion = "7.1.2"
144+
122145
configurations.all {
123146
resolutionStrategy {
124147
force(
125-
"com.google.guava:guava:$guavaVersion",
126-
148+
"com.google.guava:guava:${guavaVersion}",
127149
"com.google.protobuf:protobuf-gradle-plugin:$protobufPluginVersion",
128150

129151
// Force Kotlin lib versions avoiding using those bundled with Gradle.
@@ -149,9 +171,29 @@ tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile> {
149171
dependencies {
150172
implementation("com.fasterxml.jackson.core:jackson-databind:$jacksonVersion")
151173
implementation("com.fasterxml.jackson.dataformat:jackson-dataformat-xml:$jacksonVersion")
152-
implementation("com.google.cloud.artifactregistry:artifactregistry-auth-common:$googleAuthToolVersion") {
174+
175+
@Suppress(
176+
"VulnerableLibrariesLocal", "RedundantSuppression" /*
177+
`artifactregistry-auth-common` has transitive dependency on Gson and Apache `commons-codec`.
178+
179+
Gson from version `2.8.6` until `2.8.9` is vulnerable to Deserialization of Untrusted Data
180+
(https://devhub.checkmarx.com/cve-details/CVE-2022-25647/).
181+
182+
Apache `commons-codec` before 1.13 is vulnerable to information exposure
183+
(https://devhub.checkmarx.com/cve-details/Cxeb68d52e-5509/).
184+
185+
We use Gson `2.10.1`and we force it in `forceProductionDependencies()`.
186+
We use `commons-code` with version `1.16.0`, forcing it in `forceProductionDependencies()`.
187+
188+
So, we should be safe with the current version `artifactregistry-auth-common` until
189+
we migrate to a later version. */
190+
)
191+
implementation(
192+
"com.google.cloud.artifactregistry:artifactregistry-auth-common:$googleAuthToolVersion"
193+
) {
153194
exclude(group = "com.google.guava")
154195
}
196+
155197
implementation("com.google.guava:guava:$guavaVersion")
156198
api("com.github.jk1:gradle-license-report:$licenseReportVersion")
157199
implementation("org.ajoberstar.grgit:grgit-core:${grGitVersion}")
@@ -165,6 +207,7 @@ dependencies {
165207
implementation("com.google.protobuf:protobuf-gradle-plugin:$protobufPluginVersion")
166208
implementation("org.jetbrains.dokka:dokka-gradle-plugin:${dokkaVersion}")
167209
implementation("org.jetbrains.dokka:dokka-base:${dokkaVersion}")
210+
implementation("gradle.plugin.com.github.johnrengelman:shadow:${shadowVersion}")
168211

169212
// https://github.com/srikanth-lingala/zip4j
170213
implementation("net.lingala.zip4j:zip4j:2.10.0")

buildSrc/src/main/kotlin/DependencyResolution.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,11 +31,11 @@ import io.spine.internal.dependency.AutoService
3131
import io.spine.internal.dependency.AutoValue
3232
import io.spine.internal.dependency.CheckerFramework
3333
import io.spine.internal.dependency.CommonsCli
34+
import io.spine.internal.dependency.CommonsCodec
3435
import io.spine.internal.dependency.CommonsLogging
3536
import io.spine.internal.dependency.Dokka
3637
import io.spine.internal.dependency.ErrorProne
3738
import io.spine.internal.dependency.FindBugs
38-
import io.spine.internal.dependency.Flogger
3939
import io.spine.internal.dependency.Gson
4040
import io.spine.internal.dependency.Guava
4141
import io.spine.internal.dependency.Hamcrest
@@ -90,8 +90,7 @@ private fun ResolutionStrategy.forceProductionDependencies() {
9090
ErrorProne.annotations,
9191
ErrorProne.core,
9292
FindBugs.annotations,
93-
Flogger.Runtime.systemBackend,
94-
Flogger.lib,
93+
Gson.lib,
9594
Guava.lib,
9695
Kotlin.reflect,
9796
Kotlin.stdLib,
@@ -124,6 +123,7 @@ private fun ResolutionStrategy.forceTransitiveDependencies() {
124123
Asm.lib,
125124
AutoValue.annotations,
126125
CommonsCli.lib,
126+
CommonsCodec.lib,
127127
CommonsLogging.lib,
128128
Gson.lib,
129129
Hamcrest.core,

buildSrc/src/main/kotlin/io/spine/internal/dependency/AssertK.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ package io.spine.internal.dependency
3131
*
3232
* [AssertK](https://github.com/willowtreeapps/assertk)
3333
*/
34+
@Deprecated("Please use Kotest assertions instead.")
3435
@Suppress("unused", "ConstPropertyName")
3536
object AssertK {
3637
private const val version = "0.26.1"

buildSrc/src/main/kotlin/io/spine/internal/dependency/CheckStyle.kt

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,21 @@
2626

2727
package io.spine.internal.dependency
2828

29-
// https://checkstyle.sourceforge.io/
30-
// See `io.spine.internal.gradle.checkstyle.CheckStyleConfig`.
29+
/**
30+
* Dependencies on Checkstyle Java linter.
31+
*
32+
* @see <a href="https://checkstyle.sourceforge.io/">Checkstyle</a>
33+
* @see [io.spine.internal.gradle.checkstyle.CheckStyleConfig]
34+
*/
3135
@Suppress("unused", "ConstPropertyName")
3236
object CheckStyle {
33-
const val version = "10.3.4"
37+
/**
38+
* The version to be used in the project.
39+
*
40+
* `10.12.1` is the last version in `10.12.0`, which does not introduce
41+
* capability conflict over `google-collections` with Guava.
42+
*
43+
* @see <a href="https://checkstyle.sourceforge.io/releasenotes.html">Checkstyle</a>
44+
*/
45+
const val version = "10.12.1"
3446
}

buildSrc/src/main/kotlin/io/spine/internal/dependency/CheckerFramework.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ package io.spine.internal.dependency
2929
// https://checkerframework.org/
3030
@Suppress("unused", "ConstPropertyName")
3131
object CheckerFramework {
32-
private const val version = "3.36.0"
32+
private const val version = "3.40.0"
3333
const val annotations = "org.checkerframework:checker-qual:${version}"
3434
@Suppress("unused")
3535
val dataflow = listOf(

buildSrc/src/main/kotlin/io/spine/internal/dependency/Dokka.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,14 +35,14 @@ object Dokka {
3535
* When changing the version, also change the version used in the
3636
* `buildSrc/build.gradle.kts`.
3737
*/
38-
const val version = "1.8.10"
38+
const val version = "1.9.10"
3939

4040
object GradlePlugin {
4141
const val id = "org.jetbrains.dokka"
4242

4343
/**
4444
* The version of this plugin is already specified in `buildSrc/build.gradle.kts`
45-
* file. Thus, when applying the plugin in project's build files, only the [id]
45+
* file. Thus, when applying the plugin to project's build files, only the [id]
4646
* should be used.
4747
*/
4848
const val lib = "${group}:dokka-gradle-plugin:${version}"
@@ -59,7 +59,7 @@ object Dokka {
5959
}
6060

6161
/**
62-
* To generate the documentation as seen from Java perspective use this plugin.
62+
* To generate the documentation as seen from the Java perspective, please use this plugin.
6363
*
6464
* @see <a href="https://github.com/Kotlin/dokka#output-formats">
6565
* Dokka output formats</a>

buildSrc/src/main/kotlin/io/spine/internal/dependency/ErrorProne.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ package io.spine.internal.dependency
3030
@Suppress("unused", "ConstPropertyName")
3131
object ErrorProne {
3232
// https://github.com/google/error-prone
33-
private const val version = "2.20.0"
33+
private const val version = "2.23.0"
3434
// https://github.com/tbroyer/gradle-errorprone-plugin/blob/v0.8/build.gradle.kts
3535
private const val javacPluginVersion = "9+181-r4173-1"
3636

@@ -48,9 +48,9 @@ object ErrorProne {
4848
const val id = "net.ltgt.errorprone"
4949
/**
5050
* The version of this plugin is already specified in `buildSrc/build.gradle.kts` file.
51-
* Thus, when applying the plugin in projects build files, only the [id] should be used.
51+
* Thus, when applying the plugin to projects build files, only the [id] should be used.
5252
*
53-
* When the plugin is used as a library (e.g. in tools), its version and the library
53+
* When the plugin is used as a library (e.g., in tools), its version and the library
5454
* artifacts are of importance.
5555
*/
5656
const val version = "3.1.0"

0 commit comments

Comments
 (0)