forked from Flibio/EconomyLite
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle.kts
76 lines (67 loc) · 1.97 KB
/
build.gradle.kts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
import org.spongepowered.gradle.plugin.config.PluginLoaders
import org.spongepowered.plugin.metadata.model.PluginDependency
val pluginName: String by ext.properties
val pluginId = pluginName.toLowerCase()
val pluginVersion: String by ext.properties
val spongeVersion: String by ext.properties
val author: String by ext.properties
val maintainer: String by ext.properties
val repository: String by ext.properties
plugins {
java
id("org.spongepowered.gradle.plugin") version "2.0.0"
id("net.kyori.blossom") version "1.2.0"
}
group = "io.github.flibio"
version = pluginVersion
repositories {
mavenCentral()
}
sponge {
apiVersion(spongeVersion)
license("MIT")
loader {
name(PluginLoaders.JAVA_PLAIN)
version(pluginVersion)
}
plugin(pluginId) {
displayName(name)
version(pluginVersion)
entrypoint("io.github.flibio.economylite.EconomyLite")
description("A fork of EconomyLite tweaked for PokeResorts use case")
links {
source(repository)
issues("$repository/issues")
}
contributor(author) {
description("Original Author")
}
contributor(maintainer) {
description("Current Maintainer")
}
dependency("spongeapi") {
loadOrder(PluginDependency.LoadOrder.AFTER)
optional(false)
}
}
}
val javaTarget = 8
java {
sourceCompatibility = JavaVersion.toVersion(javaTarget)
targetCompatibility = JavaVersion.toVersion(javaTarget)
}
blossom {
replaceToken("@version@", pluginVersion, "src/main/java/io/github/flibio/economylite/PluginInfo.java")
}
tasks.withType(JavaCompile::class).configureEach {
options.apply {
encoding = "utf-8"
if (JavaVersion.current().isJava10Compatible) {
release.set(javaTarget)
}
}
}
tasks.withType(AbstractArchiveTask::class).configureEach {
isReproducibleFileOrder = true
isPreserveFileTimestamps = false
}