-
Notifications
You must be signed in to change notification settings - Fork 28
/
build.gradle
124 lines (89 loc) · 2.84 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
114
115
116
117
118
119
120
121
122
123
124
group 'me.iblitzkriegi.vixio'
buildscript {
repositories {
jcenter()
}
dependencies {
classpath 'com.github.jengelman.gradle.plugins:shadow:2.0.2'
classpath 'com.github.ben-manes:gradle-versions-plugin:0.17.0'
classpath 'de.undercouch:gradle-download-task:3.3.0'
}
}
apply plugin: 'com.github.johnrengelman.shadow'
apply plugin: 'com.github.ben-manes.versions'
apply plugin: 'de.undercouch.download'
apply plugin: 'java'
compileJava.options.encoding = 'UTF-8'
compileTestJava.options.encoding = 'UTF-8'
sourceCompatibility = 1.8
repositories {
jcenter()
//Spigot API
maven {
name 'spigot-repo'
url 'https://hub.spigotmc.org/nexus/content/repositories/snapshots/'
}
//LavaPlayer
maven {
url 'http://maven.sedmelluq.com'
}
mavenCentral() // for transitive dependencies
maven {
name 'm2-dv8tion'
url 'https://m2.dv8tion.net/releases'
}
//Bungeecord-chat (needed for Spigot)
maven {
url 'https://oss.sonatype.org/content/repositories/snapshots/'
}
//Skript's dependencies (to avoid errors when compiling)
maven {
url 'https://repo.destroystokyo.com/repository/maven-public/'
}
maven {
url 'http://maven.sk89q.com/repo'
}
maven {
url 'http://nexus.hc.to/content/repositories/pub_releases'
}
maven {
url 'https://jitpack.io'
}
}
dependencies {
// Spigot API
shadow group: 'org.spigotmc', name: 'spigot-api', version: project.property('apiversion')
// JDA
compile "net.dv8tion:JDA:4.2.1_261"
implementation(group: 'com.github.SkriptLang', name: 'Skript', version: '2.5.3') { exclude group: 'com.sk89q.worldguard', module: 'worldguard-legacy' exclude group: 'net.milkbowl.vault', module: 'Vault' }
// LavaPlayer
compile 'com.sedmelluq:lavaplayer:1.3.76'
compile 'club.minnced:opus-java-api:v1.0.4'
compile 'ch.qos.logback:logback-classic:1.2.3'
compile 'com.vdurmont:emoji-java:3.3.0'
compile group: 'org.json', name: 'json', version: '20180813'
}
jar.enabled = false
assemble.dependsOn(shadowJar)
def pluginDir = 'src/main/resources/plugin.yml'
def tempDir = 'build/tmp/tempResources'
processResources.doFirst {
copy {
from(pluginDir)
into(tempDir)
}
ant.replace(file: pluginDir, token: '@VERSION@', value: project.property('version'))
}
processResources.doLast {
copy {
from(tempDir + '/plugin.yml')
into(project.file(pluginDir).parent)
}
}
shadowJar {
classifier = ''
relocate 'org.apache.commons.lang3', project.group + ".org.apache.commons.lang3"
relocate 'org.apache.http', project.group + ".org.apache.http"
relocate 'org.apache.commons.io', project.group + ".org.apache.commons.io"
destinationDir = new File(project.property('destinationDir'))
}