build: 优化构建脚本
This commit is contained in:
@@ -26,15 +26,19 @@ dependencies {
|
||||
|
||||
compileOnly("me.clip:placeholderapi:2.11.6")
|
||||
}
|
||||
java {
|
||||
sourceCompatibility = JavaVersion.VERSION_1_8
|
||||
targetCompatibility = JavaVersion.VERSION_1_8
|
||||
withSourcesJar()
|
||||
}
|
||||
|
||||
sourceSets.create("templates") {
|
||||
java {
|
||||
srcDir("src/main/templates")
|
||||
}
|
||||
val templates = sourceSets.create("templates")!!
|
||||
templates.java {
|
||||
srcDir("src/main/templates")
|
||||
}
|
||||
|
||||
val templateSource = file("src/main/templates")
|
||||
val templateDest = layout.buildDirectory.dir("generated/sources/templates")
|
||||
val templateDest = layout.buildDirectory.dir("generated/sources/templates")!!
|
||||
val generateTemplates = tasks.register<Copy>("generateTemplates") {
|
||||
from(templateSource)
|
||||
into(templateDest)
|
||||
@@ -51,9 +55,6 @@ tasks {
|
||||
from(rootProject.file("LICENSE"))
|
||||
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
|
||||
}
|
||||
java {
|
||||
withSourcesJar()
|
||||
}
|
||||
jar {
|
||||
archiveBaseName = "HamsterBall-Bridge"
|
||||
destinationDirectory = rootProject.layout.buildDirectory
|
||||
|
||||
@@ -1,2 +1,6 @@
|
||||
rootProject.name = "hamster-ball-bridge"
|
||||
|
||||
pluginManagement {
|
||||
repositories {
|
||||
maven("https://maven.airgame.net/maven-public/")
|
||||
}
|
||||
}
|
||||
rootProject.name = "hamster-ball-bridge"
|
||||
Reference in New Issue
Block a user