From 42f63b274950e75b3029a82a386d61837a4e85ac Mon Sep 17 00:00:00 2001 From: Jason Penilla <11360596+jpenilla@users.noreply.github.com> Date: Sat, 3 Jul 2021 17:00:15 -0700 Subject: [PATCH] build/kotlin-extensions: Do not expose kotlin-stdlib dependency to API consumers --- cloud-kotlin-extensions/build.gradle.kts | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/cloud-kotlin-extensions/build.gradle.kts b/cloud-kotlin-extensions/build.gradle.kts index d9fc459c..cb234268 100644 --- a/cloud-kotlin-extensions/build.gradle.kts +++ b/cloud-kotlin-extensions/build.gradle.kts @@ -6,6 +6,16 @@ plugins { id("org.jetbrains.dokka") version "1.4.20" } +configurations.all { + dependencies.removeIf { it.group == "org.jetbrains.kotlin" } +} + +dependencies { + api(project(":cloud-core")) + implementation(kotlin("stdlib-jdk8")) + testImplementation("org.jetbrains.kotlin", "kotlin-test-junit5") +} + tasks { withType().configureEach { dokkaSourceSets.getByName("main") { @@ -32,8 +42,3 @@ tasks { kotlin { explicitApi() } - -dependencies { - api(project(":cloud-core")) - testImplementation("org.jetbrains.kotlin", "kotlin-test-junit5") -}