Add task which collects shadowed jars in root project build/libs folder

This commit is contained in:
Jonas Herzig
2019-03-15 14:50:56 +01:00
parent f795b27251
commit 44151876cd
3 changed files with 16 additions and 5 deletions

View File

@@ -34,6 +34,18 @@ subprojects {
apply plugin: 'idea'
}
evaluationDependsOnChildren()
task shadowJar(type: Copy) {
subprojects.forEach {
def shadowJar = it.tasks.findByName('shadowJar')
if (shadowJar != null && it.name != 'core') {
dependsOn shadowJar
from shadowJar.archivePath
}
}
into "$buildDir/libs"
}
def gitDescribe() {
try {
def stdout = new ByteArrayOutputStream()
@@ -155,4 +167,4 @@ task doRelease() {
}
}
defaultTasks 'build'
defaultTasks 'shadowJar'