build: exclude shadow jar from publishing to maven

This commit is contained in:
Skylot 2024-11-10 17:25:03 +00:00
parent e644bad758
commit b4ca566a19
No known key found for this signature in database
GPG Key ID: 47A4975761262B6A
2 changed files with 10 additions and 3 deletions

View File

@ -30,7 +30,7 @@ publishing {
}
pom {
name.set(project.name)
description.set("Dex to Java decompiler")
description.set(project.description ?: "Dex to Java decompiler")
url.set("https://github.com/skylot/jadx")
licenses {
license {
@ -47,9 +47,9 @@ publishing {
}
}
scm {
connection .set("scm:git:git://github.com/skylot/jadx.git")
connection.set("scm:git:git://github.com/skylot/jadx.git")
developerConnection.set("scm:git:ssh://github.com:skylot/jadx.git")
url .set("https://github.com/skylot/jadx")
url.set("https://github.com/skylot/jadx")
}
}
}

View File

@ -100,6 +100,13 @@ tasks.shadowJar {
}
}
// workaround to exclude shadowJar 'all' artifact from publishing to maven
project.components.withType(AdhocComponentWithVariants::class.java).forEach { c ->
c.withVariantsFromConfiguration(project.configurations.shadowRuntimeElements.get()) {
skip()
}
}
tasks.startShadowScripts {
doLast {
val newContent =