Automatically update version in plugin.yml
This commit is contained in:
parent
1e7d3c7d93
commit
1672fccced
|
|
@ -1,4 +1,3 @@
|
|||
import com.github.jengelman.gradle.plugins.shadow.tasks.ConfigureShadowRelocation
|
||||
import java.io.ByteArrayOutputStream
|
||||
|
||||
plugins {
|
||||
|
|
@ -26,20 +25,16 @@ tasks {
|
|||
options.encoding = Charsets.UTF_8.name()
|
||||
}
|
||||
|
||||
shadowJar {
|
||||
dependsOn(getByName("relocateJars") as ConfigureShadowRelocation)
|
||||
archiveFileName.set("${project.name}-${project.version}.jar")
|
||||
minimize()
|
||||
configurations = listOf(project.configurations.shadow.get())
|
||||
jar {
|
||||
archiveFileName.set("${rootProject.name}.jar")
|
||||
}
|
||||
|
||||
build {
|
||||
dependsOn(shadowJar)
|
||||
}
|
||||
|
||||
create<ConfigureShadowRelocation>("relocateJars") {
|
||||
target = shadowJar.get()
|
||||
prefix = "${project.name}.lib"
|
||||
processResources {
|
||||
filteringCharset = Charsets.UTF_8.name()
|
||||
duplicatesStrategy = DuplicatesStrategy.INCLUDE
|
||||
filesMatching("plugin.yml") {
|
||||
expand(Pair("projectVersion", project.version))
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
main: com.alttd.afkdectector.AFKDetector
|
||||
name: AFKDetector
|
||||
version: 2.0
|
||||
version: ${projectVersion}
|
||||
api-version: 1.18
|
||||
author: Destro174
|
||||
softdepend:
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user