Created
April 30, 2020 11:11
-
-
Save priyanshus/ed1a6eacf18a2314108d4b56c02ab750 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
task uberJar(type: Jar) { | |
manifest { | |
attributes 'Main-Class': 'main.RunTest' | |
} | |
dependsOn configurations.runtimeClasspath | |
from sourceSets.main.output | |
from sourceSets.test.output | |
from sourceSets.main.resources | |
from sourceSets.test.resources | |
from { | |
configurations.runtimeClasspath.findAll { it.name.endsWith('jar') }.collect { zipTree(it) } | |
} | |
from { | |
project(':someothermoudule').sourceSets.main.resources // If current project depends on some other modules | |
project(':someothermoudule').sourceSets.test.resources // If current project depends on some other modules | |
} | |
exclude 'META-INF/*.RSA' | |
exclude 'META-INF/*.SF' | |
exclude 'META-INF/*.DSA' | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment