Build: Use runtimeOnly instead of deprecated runtime

maven-publish plugin uses `runtimeOnly` for runtime scope instead of
`runtime`
This commit is contained in:
Vyacheslav Gerasimov
2020-04-27 17:42:38 +03:00
parent 8737168d41
commit 4aa3040550
20 changed files with 56 additions and 54 deletions

View File

@@ -6,7 +6,7 @@ plugins {
dependencies {
compile(project(":compiler:cli"))
compile(project(":compiler:ir.serialization.js"))
runtime(project(":kotlin-reflect"))
runtimeOnly(project(":kotlin-reflect"))
if (Platform[193].orLower()) {
compile(intellijDep()) { includeJars("picocontainer", rootProject = rootProject) }
}

View File

@@ -19,10 +19,10 @@ dependencies {
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
compileOnly(intellijDep()) { includeJars("trove4j") }
runtime(project(":kotlin-reflect"))
runtimeOnly(project(":kotlin-reflect"))
embedded(project(":daemon-common")) { isTransitive = false }
compile(commonDep("org.jetbrains.kotlinx", "kotlinx-coroutines-core")) {
api(commonDep("org.jetbrains.kotlinx", "kotlinx-coroutines-core")) {
isTransitive = false
}
}

View File

@@ -32,8 +32,8 @@ dependencies {
nativePlatformVariants.forEach {
embedded(commonDep("net.rubygrapefruit", "native-platform", "-$it"))
}
runtime(project(":kotlin-reflect"))
compile(commonDep("org.jetbrains.kotlinx", "kotlinx-coroutines-core")) {
runtimeOnly(project(":kotlin-reflect"))
api(commonDep("org.jetbrains.kotlinx", "kotlinx-coroutines-core")) {
isTransitive = false
}
}

View File

@@ -5,6 +5,7 @@ plugins {
dependencies {
testCompileOnly(intellijDep())
testCompileOnly(project(":kotlin-reflect-api"))
testCompile(project(":idea:jvm-debugger:jvm-debugger-core"))
testCompile(project(":idea:jvm-debugger:jvm-debugger-evaluation"))

View File

@@ -10,13 +10,13 @@ val packedJars by configurations.creating
dependencies {
packedJars(project(":kotlin-scripting-jsr223-unshaded")) { isTransitive = false }
runtime(project(":kotlin-script-runtime"))
runtime(kotlinStdlib())
runtime(project(":kotlin-scripting-common"))
runtime(project(":kotlin-scripting-jvm"))
runtime(project(":kotlin-scripting-jvm-host"))
runtime(project(":kotlin-compiler-embeddable"))
runtime(project(":kotlin-scripting-compiler-embeddable"))
runtimeOnly(project(":kotlin-script-runtime"))
runtimeOnly(kotlinStdlib())
runtimeOnly(project(":kotlin-scripting-common"))
runtimeOnly(project(":kotlin-scripting-jvm"))
runtimeOnly(project(":kotlin-scripting-jvm-host"))
runtimeOnly(project(":kotlin-compiler-embeddable"))
runtimeOnly(project(":kotlin-scripting-compiler-embeddable"))
}
sourceSets {

View File

@@ -6,12 +6,12 @@ plugins { java }
dependencies {
embedded(project(":kotlin-scripting-jvm-host-unshaded")) { isTransitive = false }
runtime(project(":kotlin-script-runtime"))
runtime(kotlinStdlib())
runtime(project(":kotlin-scripting-common"))
runtime(project(":kotlin-scripting-jvm"))
runtime(project(":kotlin-compiler-embeddable"))
runtime(project(":kotlin-scripting-compiler-embeddable"))
runtimeOnly(project(":kotlin-script-runtime"))
runtimeOnly(kotlinStdlib())
runtimeOnly(project(":kotlin-scripting-common"))
runtimeOnly(project(":kotlin-scripting-jvm"))
runtimeOnly(project(":kotlin-compiler-embeddable"))
runtimeOnly(project(":kotlin-scripting-compiler-embeddable"))
}
sourceSets {

View File

@@ -10,9 +10,9 @@ plugins {
val packedJars by configurations.creating
dependencies {
compile(kotlinStdlib())
api(kotlinStdlib())
packedJars(project(":kotlin-annotation-processing")) { isTransitive = false }
runtime(projectRuntimeJar(":kotlin-compiler-embeddable"))
runtimeOnly(projectRuntimeJar(":kotlin-compiler-embeddable"))
}
projectTest(parallel = true) {

View File

@@ -60,13 +60,13 @@ dependencies {
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
runtime(projectRuntimeJar(":kotlin-compiler-embeddable"))
runtime(projectRuntimeJar(":kotlin-annotation-processing-gradle"))
runtime(projectRuntimeJar(":kotlin-android-extensions"))
runtime(projectRuntimeJar(":kotlin-compiler-runner"))
runtime(projectRuntimeJar(":kotlin-scripting-compiler-embeddable"))
runtime(projectRuntimeJar(":kotlin-scripting-compiler-impl-embeddable"))
runtime(project(":kotlin-reflect"))
runtimeOnly(projectRuntimeJar(":kotlin-compiler-embeddable"))
runtimeOnly(projectRuntimeJar(":kotlin-annotation-processing-gradle"))
runtimeOnly(projectRuntimeJar(":kotlin-android-extensions"))
runtimeOnly(projectRuntimeJar(":kotlin-compiler-runner"))
runtimeOnly(projectRuntimeJar(":kotlin-scripting-compiler-embeddable"))
runtimeOnly(projectRuntimeJar(":kotlin-scripting-compiler-impl-embeddable"))
runtimeOnly(project(":kotlin-reflect"))
jarContents(compileOnly(intellijDep()) {
includeJars("asm-all", "gson", "serviceMessages", rootProject = rootProject)

View File

@@ -29,10 +29,10 @@ dependencies {
compileOnly(project(":compiler:cli-common"))
compileOnly(project(":kotlin-scripting-jvm-host-unshaded"))
compileOnly(project(":kotlin-scripting-dependencies"))
runtime(project(":kotlin-compiler-embeddable"))
runtime(project(":kotlin-scripting-compiler-embeddable"))
runtime(project(":kotlin-scripting-jvm-host"))
runtime(project(":kotlin-reflect"))
runtimeOnly(project(":kotlin-compiler-embeddable"))
runtimeOnly(project(":kotlin-scripting-compiler-embeddable"))
runtimeOnly(project(":kotlin-scripting-jvm-host"))
runtimeOnly(project(":kotlin-reflect"))
embedded(project(":kotlin-scripting-common")) { isTransitive = false }
embedded(project(":kotlin-scripting-jvm")) { isTransitive = false }
embedded(project(":kotlin-scripting-jvm-host-unshaded")) { isTransitive = false }

View File

@@ -96,4 +96,4 @@ artifacts {
}
}
publish()
publishWithLegacyMavenPlugin()

View File

@@ -12,6 +12,7 @@ dependencies {
testImplementation(projectTests(":compiler:tests-common"))
testImplementation(project(":kotlin-test:kotlin-test-junit"))
testImplementation(project(":kotlin-reflect"))
testImplementation(commonDep("junit:junit"))
testImplementation(intellijDep())
}

View File

@@ -6,8 +6,8 @@ plugins {
dependencies {
embedded(project(":native:kotlin-klib-commonizer")) { isTransitive = false }
runtime(kotlinStdlib())
runtime(project(":kotlin-compiler-embeddable"))
runtimeOnly(kotlinStdlib())
runtimeOnly(project(":kotlin-compiler-embeddable"))
}
sourceSets {

View File

@@ -11,7 +11,7 @@ dependencies {
compileOnly(project(":compiler:frontend"))
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }
runtime(kotlinStdlib())
runtimeOnly(kotlinStdlib())
testCompile(project(":compiler:backend"))
testCompile(project(":compiler:cli"))

View File

@@ -18,7 +18,7 @@ dependencies {
compileOnly(project(":js:js.translator"))
compileOnly(project(":kotlin-util-klib-metadata"))
runtime(kotlinStdlib())
runtimeOnly(kotlinStdlib())
testCompile(projectTests(":compiler:tests-common"))
testCompile(commonDep("junit:junit"))

View File

@@ -7,8 +7,8 @@ description = "Kotlin Scripting Compiler Plugin for embeddable compiler"
val packedJars by configurations.creating
dependencies {
packedJars(project(":kotlin-scripting-compiler")) { isTransitive = false }
runtime(project(":kotlin-scripting-compiler-impl-embeddable"))
runtime(kotlinStdlib())
runtimeOnly(project(":kotlin-scripting-compiler-impl-embeddable"))
runtimeOnly(kotlinStdlib())
}
publish()

View File

@@ -7,10 +7,10 @@ description = "Kotlin Compiler Infrastructure for Scripting for embeddable compi
val packedJars by configurations.creating
dependencies {
packedJars(project(":kotlin-scripting-compiler-impl")) { isTransitive = false }
runtime(project(":kotlin-scripting-common"))
runtime(project(":kotlin-scripting-jvm"))
runtime(kotlinStdlib())
runtime(commonDep("org.jetbrains.kotlinx", "kotlinx-coroutines-core")) { isTransitive = false }
runtimeOnly(project(":kotlin-scripting-common"))
runtimeOnly(project(":kotlin-scripting-jvm"))
runtimeOnly(kotlinStdlib())
runtimeOnly(commonDep("org.jetbrains.kotlinx", "kotlinx-coroutines-core")) { isTransitive = false }
}
publish()

View File

@@ -24,7 +24,7 @@ dependencies {
// FIXME: drop after removing references to LocalFileSystem they don't exist in intellij-core
compileOnly(intellijDep()) { includeJars("platform-api") }
runtime(project(":kotlin-reflect"))
runtimeOnly(project(":kotlin-reflect"))
testCompile(project(":compiler:frontend"))
testCompile(project(":compiler:plugin-api"))

View File

@@ -5,12 +5,12 @@ plugins { java }
dependencies {
embedded(project(":kotlin-scripting-ide-services-unshaded")) { isTransitive = false }
embedded(project(":idea:ide-common")) { isTransitive = false }
runtime(project(":kotlin-script-runtime"))
runtime(kotlinStdlib())
runtime(project(":kotlin-scripting-common"))
runtime(project(":kotlin-scripting-jvm"))
runtime(project(":kotlin-compiler-embeddable"))
runtime(project(":kotlin-scripting-compiler-embeddable"))
runtimeOnly(project(":kotlin-script-runtime"))
runtimeOnly(kotlinStdlib())
runtimeOnly(project(":kotlin-scripting-common"))
runtimeOnly(project(":kotlin-scripting-jvm"))
runtimeOnly(project(":kotlin-compiler-embeddable"))
runtimeOnly(project(":kotlin-scripting-compiler-embeddable"))
}
sourceSets {

View File

@@ -14,7 +14,7 @@ dependencies {
compileOnly(project(":compiler:frontend.java"))
compileOnly(project(":compiler:backend"))
compileOnly(project(":kotlin-android-extensions-runtime"))
runtime(projectRuntimeJar(":kotlin-compiler-embeddable"))
runtimeOnly(projectRuntimeJar(":kotlin-compiler-embeddable"))
compileOnly(commonDep("com.google.android", "android"))
compileOnly(intellijCoreDep()) { includeJars("intellij-core") }

View File

@@ -8,11 +8,11 @@ plugins {
val testCompilationClasspath by configurations.creating
dependencies {
runtime(kotlinStdlib())
runtime(project(":kotlin-script-runtime"))
runtime(project(":kotlin-reflect"))
runtimeOnly(kotlinStdlib())
runtimeOnly(project(":kotlin-script-runtime"))
runtimeOnly(project(":kotlin-reflect"))
runtime(project(":kotlin-daemon-embeddable"))
runtime(commonDep("org.jetbrains.intellij.deps", "trove4j"))
runtimeOnly(commonDep("org.jetbrains.intellij.deps", "trove4j"))
testCompile(commonDep("junit:junit"))
testCompile(project(":kotlin-test:kotlin-test-junit"))
testCompilationClasspath(kotlinStdlib())