summaryrefslogtreecommitdiff
path: root/build.gradle
diff options
context:
space:
mode:
authorSergey Shanshin <sergey.shanshin@jetbrains.com>2022-11-22 17:55:51 +0300
committerGitHub <noreply@github.com>2022-11-22 17:55:51 +0300
commitd1640e6361848d03ad0627f205bce298404769bf (patch)
tree44d2fa48bf54b290d9bdafd59fe05fe8c4b400b4 /build.gradle
parentbc6112eebc32db4fdab6d7b34a7debab91545d4a (diff)
downloadkotlinx.serialization-d1640e6361848d03ad0627f205bce298404769bf.tar.gz
Introduced BOM to have all the dependencies aligned (#2093)
Added dependency on kotlinx-serialization-bom inside other kotlinx-serialization modules themselves, so they have same versions through it Resolves #2053
Diffstat (limited to 'build.gradle')
-rw-r--r--build.gradle14
1 files changed, 11 insertions, 3 deletions
diff --git a/build.gradle b/build.gradle
index 170a9df9..56f3f0a0 100644
--- a/build.gradle
+++ b/build.gradle
@@ -147,6 +147,8 @@ allprojects {
}
def unpublishedProjects = ["benchmark", "guide", "kotlinx-serialization-json-tests"] as Set
+def excludedFromBomProjects = unpublishedProjects + "kotlinx-serialization-bom" as Set
+def uncoveredProjects = ["kotlinx-serialization-bom", "benchmark", "guide"] as Set
subprojects {
tasks.withType(org.jetbrains.kotlin.gradle.tasks.AbstractKotlinCompile).all { task ->
@@ -162,12 +164,11 @@ subprojects {
if (!unpublishedProjects.contains(project.name)) {
apply from: rootProject.file('gradle/publishing.gradle')
}
-
}
subprojects {
// Can't be applied to BOM
- if (project.name == "kotlinx-serialization-bom" || project.name == "benchmark" || project.name == "guide") return
+ if (excludedFromBomProjects.contains(project.name)) return
// Animalsniffer setup
apply plugin: 'ru.vyarus.animalsniffer'
@@ -190,9 +191,16 @@ subprojects {
signature 'net.sf.androidscents.signature:android-api-level-14:4.0_r4@signature'
signature 'org.codehaus.mojo.signature:java18:1.0@signature'
}
+
+ // Add dependency on kotlinx-serialization-bom inside other kotlinx-serialization modules themselves, so they have same versions
+ BomKt.addBomApiDependency(project, ":kotlinx-serialization-bom")
}
+}
+
+// Kover setup
+subprojects {
+ if (uncoveredProjects.contains(project.name)) return
- // Kover setup
apply from: rootProject.file("gradle/kover.gradle")
}