[build] Rename task for expanded sources jar
This commit is contained in:
@@ -14,14 +14,14 @@ val expandedSourcesElements = configurations.consumable("expandedSourcesElements
|
|||||||
|
|
||||||
val delombok = tasks.getByName<Delombok>("delombok")
|
val delombok = tasks.getByName<Delombok>("delombok")
|
||||||
|
|
||||||
val sourcesJarTask by tasks.registering(Jar::class) {
|
val sourcesJar by tasks.registering(Jar::class) {
|
||||||
dependsOn(delombok)
|
dependsOn(delombok)
|
||||||
from(delombok.target)
|
from(delombok.target)
|
||||||
archiveClassifier.set("sources")
|
archiveClassifier.set("sources")
|
||||||
}
|
}
|
||||||
artifacts.add(expandedSourcesElements.name, sourcesJarTask)
|
artifacts.add(expandedSourcesElements.name, sourcesJar)
|
||||||
|
|
||||||
tasks.named("build") { dependsOn(sourcesJarTask) }
|
tasks.named("build") { dependsOn(sourcesJar) }
|
||||||
|
|
||||||
components.named<AdhocComponentWithVariants>("java") {
|
components.named<AdhocComponentWithVariants>("java") {
|
||||||
addVariantsFromConfiguration(expandedSourcesElements.get()) {}
|
addVariantsFromConfiguration(expandedSourcesElements.get()) {}
|
||||||
|
|||||||
Reference in New Issue
Block a user