Created
June 18, 2018 15:23
-
-
Save Ingwersaft/68d3ff19abc2ffcf73e61d23b6748a02 to your computer and use it in GitHub Desktop.
gradle kotlin dsl: runnable uber jar
This file contains hidden or 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
| tasks.withType<Jar> { | |
| manifest { | |
| attributes["Main-Class"] = "<todo> | |
| } | |
| from(configurations.runtime | |
| .filterNot { it.path.endsWith(".pom") } | |
| .map { | |
| if (it.isDirectory) { | |
| it | |
| } else { | |
| zipTree(it) | |
| } | |
| }) { | |
| exclude("META-INF/*.SF") | |
| exclude("META-INF/*.DSA") | |
| exclude("META-INF/*.RSA") | |
| exclude("**/pom.xml") | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment