Add a server build task
This commit is contained in:
parent
9ae9ebbfa0
commit
a48a85f943
1 changed files with 24 additions and 1 deletions
25
build.gradle
25
build.gradle
|
@ -127,4 +127,27 @@ task jarjar(type: Jar) {
|
|||
|
||||
jar.finalizedBy(jarjar)
|
||||
jar.finalizedBy(copyToLib)
|
||||
jar.finalizedBy(copyNatives)
|
||||
jar.finalizedBy(copyNatives)
|
||||
|
||||
|
||||
|
||||
task buildServer(type: Jar){
|
||||
manifest {
|
||||
attributes(
|
||||
'Main-Class': "com.mojang.minecraft.server.MinecraftServer",
|
||||
"Multi-Release": 'true'
|
||||
)
|
||||
} from {
|
||||
configurations.provided.collect { it.isDirectory() ? it : zipTree(it)}
|
||||
}
|
||||
archiveClassifier = "server"
|
||||
duplicatesStrategy = "exclude"
|
||||
from {configurations.provided.collect {it.isDirectory()?it:zipTree(it)}}
|
||||
|
||||
exclude 'META-INF/*'
|
||||
|
||||
with jarjar
|
||||
}
|
||||
|
||||
|
||||
jar.finalizedBy(buildServer)
|
Loading…
Reference in a new issue