-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
114 lines (87 loc) · 2.74 KB
/
build.gradle
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
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
plugins {
id 'java'
id 'org.jetbrains.kotlin.jvm' version '1.9.22'
}
group = 'org.ndk'
version = '1.0.0'
repositories {
mavenCentral()
maven {
name = "spigotmc-repo"
url = "https://hub.spigotmc.org/nexus/content/repositories/snapshots/"
}
maven {
name = "sonatype"
url = "https://oss.sonatype.org/content/groups/public/"
}
maven {
name = "enginehub"
url = "https://maven.enginehub.org/repo/"
}
maven {
url = "https://repo.xenondevs.xyz/releases"
}
maven {
url "https://repo.destroystokyo.com/repository/maven-public/"
}
mavenLocal()
flatDir {
dirs 'C:\\Users\\nikdekur\\.m2\\repository\\org\\ndk\\NDKGlobal\\1.0.0'
dirs 'C:\\Users\\nikdekur\\.m2\\repository\\org\\ndk\\NDKMinecraft\\1.0.0'
dirs 'C:\\Users\\nikdekur\\.m2\\repository\\org\\ndk\\database\\1.0.0'
}
}
dependencies {
implementation 'org.ndk:NDKGlobal:1.0.0'
implementation 'org.ndk:NDKMinecraft:1.0.0'
implementation 'org.ndk:database:1.0.0'
implementation 'org.mariadb.jdbc:mariadb-java-client:2.7.11'
compileOnly 'com.sk89q.worldedit:worldedit-bukkit:6.1.5'
compileOnly 'com.sk89q.worldedit:worldedit-core:6.1.4-SNAPSHOT'
implementation "org.jetbrains.kotlinx:kotlinx-coroutines-core:1.8.0-RC2"
compileOnly "org.jetbrains.kotlin:kotlin-reflect:1.9.22"
implementation "xyz.xenondevs.invui:invui:1.27"
// Spigot
compileOnly 'org.spigotmc:spigot:1.12.2-R0.1-SNAPSHOT'
// Paper
compileOnly 'com.destroystokyo.paper:paper-api:1.12.2-R0.1-SNAPSHOT'
}
def targetJavaVersion = 8
java {
def javaVersion = JavaVersion.toVersion(targetJavaVersion)
sourceCompatibility = javaVersion
targetCompatibility = javaVersion
if (JavaVersion.current() < javaVersion) {
toolchain.languageVersion = JavaLanguageVersion.of(targetJavaVersion)
}
}
kotlin {
jvmToolchain(8)
}
processResources {
def props = [version: version]
inputs.properties props
filteringCharset 'UTF-8'
filesMatching('plugin.yml') {
expand props
}
}
jar {
manifest {
attributes["Main-Class"] = 'org.ndk.godsimulator.GodSimulator'
}
// To avoid the duplicate handling strategy error
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
// To add all of the dependencies
from(sourceSets.main.output)
from({
configurations.runtimeClasspath.filter {
def f = it as File
f.name.endsWith("jar")
}.toList().stream().map {
zipTree(it)
}.collect()
})
exclude("META-INF/*.RSA", "META-INF/*.DSA", "META-INF/*.SF")
destinationDirectory.set(file("C:\\codes\\Java\\Projects\\GodSimulator\\out\\GodSimulator.jar"))
}