-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathbuild.gradle
111 lines (97 loc) · 3.04 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
plugins {
id 'java'
id 'io.github.goooler.shadow' version '8.1.8'
id 'net.kyori.blossom' version '2.1.0'
}
group = 'io.greitan'
version = project.hasProperty('VERSION') ? project.VERSION : 'UNKNOWN'
description = "Plugin that adds support for using VoiceCraft on Java servers."
repositories {
mavenCentral()
maven {
name = "CodeMC"
url = uri("https://repo.codemc.io/repository/maven-public/")
}
maven {
name = "PaperMC"
url = "https://repo.papermc.io/repository/maven-public/"
}
maven {
name = "PlaceholderAPI"
url = 'https://repo.extendedclip.com/content/repositories/placeholderapi/'
}
maven {
name = "Jitpack"
url = 'https://jitpack.io'
}
maven {
name = "Bungeecord"
url 'https://oss.sonatype.org/content/repositories/snapshots'
}
}
dependencies {
compileOnly 'dev.folia:folia-api:1.20.2-R0.1-SNAPSHOT'
compileOnly 'io.papermc.paper:paper-api:1.20.2-R0.1-SNAPSHOT'
compileOnly 'com.velocitypowered:velocity-api:3.3.0-SNAPSHOT'
annotationProcessor 'com.velocitypowered:velocity-api:3.3.0-SNAPSHOT'
compileOnly 'net.md-5:bungeecord-api:1.20-R0.2'
compileOnly 'me.clip:placeholderapi:2.11.6'
compileOnly 'org.projectlombok:lombok:1.18.30'
annotationProcessor 'org.projectlombok:lombok:1.18.30'
implementation('com.fasterxml.jackson.core:jackson-databind:2.15.2')
implementation('com.fasterxml.jackson.core:jackson-core:2.15.2')
implementation("com.github.simplix-softworks:simplixstorage:3.2.3")
}
sourceSets {
main {
blossom {
javaSources {
property("name", "GeyserVoice")
property("version", version.toString())
property("description", description)
property("url", "https://uninode.de")
}
resources {
property("name", "GeyserVoice")
property("version", version.toString())
property("description", description)
property("url", "https://uninode.de")
}
}
}
}
tasks.withType(JavaCompile) {
options.encoding = 'UTF-8'
}
tasks.withType(Javadoc) {
options.encoding = 'UTF-8'
options.charSet = 'UTF-8'
}
tasks.withType(Test) {
systemProperty 'file.encoding', 'UTF-8'
}
java {
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
}
shadowJar {
archiveClassifier.set('all')
relocate 'com.tcoded.folialib', 'io.greitan.avion.folialib'
}
task deleteUnusableJar(type: Delete) {
doLast {
file("build/libs").listFiles().each { File file ->
if (file.name.endsWith(".jar") && !file.name.contains("-all")) {
file.delete()
}
}
}
}
task copyToTestServer(type: Copy) {
from shadowJar
into "D:\\JavaTest\\plugins"
}
copyToTestServer.dependsOn shadowJar
build.finalizedBy shadowJar
shadowJar.finalizedBy deleteUnusableJar
if (project.hasProperty('DEV')) shadowJar.finalizedBy copyToTestServer