4
0
Fork 0
mirror of https://github.com/Anvilcraft/modpacktools synced 2024-05-28 16:24:15 +02:00

add application plugin and fatJar task to build.gradle

This commit is contained in:
LordMZTE 2020-04-30 21:00:36 +02:00
parent 151e8cac5f
commit 2781246faf
2 changed files with 17 additions and 2 deletions

View file

@ -1,5 +1,6 @@
plugins {
id 'java'
id 'application'
}
group 'ley.anvil'
@ -17,3 +18,16 @@ dependencies {
compile "com.github.TheRandomLabs:CurseAPI:master-SNAPSHOT"
testCompile group: 'junit', name: 'junit', version: '4.12'
}
mainClassName = 'ley.anvil.modpacktools.Main'
//create a single Jar with all dependencies
task fatJar(type: Jar) {
clean
manifest {
attributes 'Main-Class': mainClassName
}
archiveBaseName = 'MCServerInfo'
from { configurations.compile.collect { it.isDirectory() ? it : zipTree(it) } }
with jar
}

View file

@ -1,5 +1,6 @@
#Thu Apr 30 20:53:50 CEST 2020
distributionUrl=https\://services.gradle.org/distributions/gradle-5.2.1-bin.zip
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-5.2.1-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME