1
- import com.github.jengelman.gradle.plugins.shadow.tasks.*
2
1
import java.net.*
3
2
import java.nio.file.*
4
3
5
4
plugins {
6
- id(" com.github.johnrengelman.shadow" )
7
5
id(" org.jetbrains.kotlinx.kover" ) // apply plugin to use autocomplete for Kover DSL
8
6
}
9
7
@@ -28,8 +26,8 @@ dependencies {
28
26
compileOnly(" org.junit.jupiter:junit-jupiter-api:$junit5_version " )
29
27
testImplementation(" org.junit.jupiter:junit-jupiter-engine:$junit5_version " )
30
28
testImplementation(" org.junit.platform:junit-platform-testkit:1.7.0" )
31
- add( " shadowDeps " , " net.bytebuddy:byte-buddy:$byte_buddy_version " )
32
- add( " shadowDeps " , " net.bytebuddy:byte-buddy-agent:$byte_buddy_version " )
29
+ implementation( " net.bytebuddy:byte-buddy:$byte_buddy_version " )
30
+ implementation( " net.bytebuddy:byte-buddy-agent:$byte_buddy_version " )
33
31
compileOnly(" io.projectreactor.tools:blockhound:$blockhound_version " )
34
32
testImplementation(" io.projectreactor.tools:blockhound:$blockhound_version " )
35
33
testImplementation(" com.google.code.gson:gson:2.8.6" )
@@ -51,20 +49,6 @@ tasks.withType<Test>().configureEach {
51
49
}
52
50
53
51
val jar by tasks.existing(Jar ::class ) {
54
- enabled = false
55
- }
56
-
57
- val shadowJar by tasks.existing(ShadowJar ::class ) {
58
- // Shadow only byte buddy, do not package kotlin stdlib
59
- configurations = listOf (project.configurations[" shadowDeps" ])
60
- relocate(" net.bytebuddy" , " kotlinx.coroutines.repackaged.net.bytebuddy" )
61
- /* These classifiers are both set to `null` to trick Gradle into thinking that this jar file is both the
62
- artifact from the `jar` task and the one from `shadowJar`. Without this, Gradle complains that the artifact
63
- from the `jar` task is not present when the compilaton finishes, even if the file with this name exists. */
64
- archiveClassifier.convention(null as String? )
65
- archiveClassifier = null
66
- archiveBaseName = jar.flatMap { it.archiveBaseName }
67
- archiveVersion = jar.flatMap { it.archiveVersion }
68
52
manifest {
69
53
attributes(
70
54
mapOf (
@@ -90,14 +74,6 @@ val shadowJar by tasks.existing(ShadowJar::class) {
90
74
}
91
75
}
92
76
93
- configurations {
94
- // shadowJar is already part of the `shadowRuntimeElements` and `shadowApiElements`, but the other subprojects
95
- // that depend on `kotlinx-coroutines-debug` look at `runtimeElements` and `apiElements`.
96
- artifacts {
97
- add(" apiElements" , shadowJar)
98
- add(" runtimeElements" , shadowJar)
99
- }
100
- }
101
77
102
78
kover {
103
79
reports {
0 commit comments