Skip to content
This repository was archived by the owner on Feb 25, 2022. It is now read-only.

Commit b007c9e

Browse files
author
melike2d
committed
update lavaplayer
1 parent 15fba35 commit b007c9e

File tree

2 files changed

+191
-190
lines changed

2 files changed

+191
-190
lines changed

LavalinkServer/build.gradle

Lines changed: 103 additions & 103 deletions
Original file line numberDiff line numberDiff line change
@@ -36,143 +36,143 @@ mainClassName = "lavalink.server.Launcher"
3636
version = "${versionFromTag()}".toString()
3737

3838
ext {
39-
moduleName = 'Lavalink-Server'
39+
moduleName = 'Lavalink-Server'
4040
}
4141

4242
bootJar {
43-
archiveFileName = "Lavalink.jar"
43+
archiveFileName = "Lavalink.jar"
4444
}
4545

4646
sourceCompatibility = targetCompatibility = 11
4747

4848
run {
49-
//compiling tests during bootRun increases the likelihood of catching broken tests locally instead of on the CI
50-
dependsOn compileTestJava
51-
52-
//pass in custom jvm args
53-
// source: https://stackoverflow.com/a/25079415
54-
// example: ./gradlew bootRun -PjvmArgs="--illegal-access=debug -Dwhatever=value"
55-
if (project.hasProperty('jvmArgs')) {
56-
jvmArgs project.jvmArgs.split('\\s+')
57-
}
49+
//compiling tests during bootRun increases the likelihood of catching broken tests locally instead of on the CI
50+
dependsOn compileTestJava
51+
52+
//pass in custom jvm args
53+
// source: https://stackoverflow.com/a/25079415
54+
// example: ./gradlew bootRun -PjvmArgs="--illegal-access=debug -Dwhatever=value"
55+
if (project.hasProperty('jvmArgs')) {
56+
jvmArgs project.jvmArgs.split('\\s+')
57+
}
5858
}
5959

6060
dependencies {
61-
implementation group: 'org.jetbrains.kotlin', name: 'kotlin-reflect', version: kotlinVersion
62-
63-
// Audio Sending
64-
implementation group: "com.sedmelluq", name: "udp-queue", version: udpQueueVersion
65-
implementation(group: 'moe.kyokobot.koe', name: 'ext-udpqueue', version: koeVersion) {
66-
exclude group: "com.sedmelluq", module: "lavaplayer"
67-
exclude group: "com.sedmelluq", module: "udp-queue"
68-
}
69-
implementation(group: 'moe.kyokobot.koe', name: 'core', version: koeVersion) {
70-
// This version of SLF4J does not recognise Logback 1.2.3
71-
exclude group: "org.slf4j", module: "slf4j-api"
72-
exclude group: "com.sedmelluq", module: "lavaplayer"
73-
}
74-
75-
// Transport
76-
implementation "io.netty:netty-transport-native-epoll:$nettyEpollVersion:linux-x86_64"
77-
78-
// Audio Player
79-
implementation group: 'com.sedmelluq', name: 'lavaplayer', version: lavaplayerVersion
80-
implementation(group: 'com.sedmelluq', name: 'lavaplayer-ext-youtube-rotator', version: lavaplayerIpRotatorVersion) {
81-
exclude group: "com.sedmelluq", module: "lavaplayer"
82-
}
83-
84-
// Filters
85-
implementation(group: 'com.github.natanbc', name: 'lavadsp', version: lavaDspVersion) {
86-
exclude group: "com.sedmelluq", module: "lavaplayer"
87-
}
88-
89-
// Spring
90-
implementation group: 'org.springframework', name: 'spring-websocket', version: springWebSocketVersion
91-
implementation(group: 'org.springframework.boot', name: 'spring-boot-starter-web', version: springBootVersion) {
92-
exclude group: 'org.springframework.boot', module: 'spring-boot-starter-tomcat'
93-
}
94-
implementation group: 'org.springframework.boot', name: 'spring-boot-starter-undertow', version: springBootVersion
95-
96-
// Logging and Statistics
97-
implementation group: 'ch.qos.logback', name: 'logback-classic', version: logbackVersion
98-
implementation group: 'io.sentry', name: 'sentry-logback', version: sentryLogbackVersion
99-
implementation group: 'io.prometheus', name: 'simpleclient', version: prometheusVersion
100-
implementation group: 'io.prometheus', name: 'simpleclient_hotspot', version: prometheusVersion
101-
implementation group: 'io.prometheus', name: 'simpleclient_logback', version: prometheusVersion
102-
implementation group: 'io.prometheus', name: 'simpleclient_servlet', version: prometheusVersion
103-
104-
// Native System Stuff
105-
implementation group: 'com.github.oshi', name: 'oshi-core', version: oshiVersion
106-
107-
// idk Json
108-
implementation group: 'org.json', name: 'json', version: jsonOrgVersion
109-
implementation group: 'com.google.code.gson', name: 'gson', version: gsonVersion
110-
111-
// Idk test stuff?
112-
compileOnly group: 'com.github.spotbugs', name: 'spotbugs-annotations', version: spotbugsAnnotationsVersion
113-
testImplementation group: 'org.springframework.boot', name: 'spring-boot-starter-test', version: springBootVersion
61+
implementation group: 'org.jetbrains.kotlin', name: 'kotlin-reflect', version: kotlinVersion
62+
63+
// Audio Sending
64+
implementation group: "com.sedmelluq", name: "udp-queue", version: udpQueueVersion
65+
implementation(group: 'moe.kyokobot.koe', name: 'ext-udpqueue', version: koeVersion) {
66+
exclude group: "com.sedmelluq", module: "lavaplayer"
67+
exclude group: "com.sedmelluq", module: "udp-queue"
68+
}
69+
implementation(group: 'moe.kyokobot.koe', name: 'core', version: koeVersion) {
70+
// This version of SLF4J does not recognise Logback 1.2.3
71+
exclude group: "org.slf4j", module: "slf4j-api"
72+
exclude group: "com.sedmelluq", module: "lavaplayer"
73+
}
74+
75+
// Transport
76+
implementation "io.netty:netty-transport-native-epoll:$nettyEpollVersion:linux-x86_64"
77+
78+
// Audio Player
79+
// implementation group: 'com.sedmelluq', name: 'lavaplayer', version: lavaplayerVersion
80+
implementation group: 'com.github.walkyst', name: 'lavaplayer-fork', version: '1.3.96'
81+
implementation(group: 'com.sedmelluq', name: 'lavaplayer-ext-youtube-rotator', version: lavaplayerIpRotatorVersion) {
82+
exclude group: "com.sedmelluq", module: "lavaplayer"
83+
}
84+
85+
// Filters
86+
implementation(group: 'com.github.natanbc', name: 'lavadsp', version: lavaDspVersion) {
87+
exclude group: "com.sedmelluq", module: "lavaplayer"
88+
}
89+
90+
// Spring
91+
implementation group: 'org.springframework', name: 'spring-websocket', version: springWebSocketVersion
92+
implementation(group: 'org.springframework.boot', name: 'spring-boot-starter-web', version: springBootVersion) {
93+
exclude group: 'org.springframework.boot', module: 'spring-boot-starter-tomcat'
94+
}
95+
implementation group: 'org.springframework.boot', name: 'spring-boot-starter-undertow', version: springBootVersion
96+
97+
// Logging and Statistics
98+
implementation group: 'ch.qos.logback', name: 'logback-classic', version: logbackVersion
99+
implementation group: 'io.sentry', name: 'sentry-logback', version: sentryLogbackVersion
100+
implementation group: 'io.prometheus', name: 'simpleclient', version: prometheusVersion
101+
implementation group: 'io.prometheus', name: 'simpleclient_hotspot', version: prometheusVersion
102+
implementation group: 'io.prometheus', name: 'simpleclient_logback', version: prometheusVersion
103+
implementation group: 'io.prometheus', name: 'simpleclient_servlet', version: prometheusVersion
104+
105+
// Native System Stuff
106+
implementation group: 'com.github.oshi', name: 'oshi-core', version: oshiVersion
107+
108+
// idk Json
109+
implementation group: 'org.json', name: 'json', version: jsonOrgVersion
110+
implementation group: 'com.google.code.gson', name: 'gson', version: gsonVersion
111+
112+
// Idk test stuff?
113+
compileOnly group: 'com.github.spotbugs', name: 'spotbugs-annotations', version: spotbugsAnnotationsVersion
114+
testImplementation group: 'org.springframework.boot', name: 'spring-boot-starter-test', version: springBootVersion
114115
}
115116

116117
processResources {
117-
//inject values into app.properties
118-
filesMatching("**/app.properties") {
119-
filter ReplaceTokens, tokens: [
120-
"project.version" : project.version,
121-
"project.groupId" : project.group,
122-
"project.artifactId": project.ext.moduleName,
123-
"env.BUILD_NUMBER" : (System.getenv('CI') ? System.getenv('BUILD_NUMBER') : 'Unofficial'),
124-
"env.BUILD_TIME" : System.currentTimeMillis() + ''
125-
]
126-
}
118+
//inject values into app.properties
119+
filesMatching("**/app.properties") {
120+
filter ReplaceTokens, tokens: [
121+
"project.version" : project.version,
122+
"project.groupId" : project.group,
123+
"project.artifactId": project.ext.moduleName,
124+
"env.BUILD_NUMBER" : (System.getenv('CI') ? System.getenv('BUILD_NUMBER') : 'Unofficial'),
125+
"env.BUILD_TIME" : System.currentTimeMillis() + ''
126+
]
127+
}
127128
}
128129

129130
build {
130-
doLast {
131-
println 'Version: ' + version
132-
}
131+
doLast {
132+
println 'Version: ' + version
133+
}
133134
}
134135

135136
test {
136-
useJUnitPlatform()
137+
useJUnitPlatform()
137138
}
138139

139140
compileKotlin {
140-
kotlinOptions {
141-
jvmTarget = "11"
142-
}
141+
kotlinOptions {
142+
jvmTarget = "11"
143+
}
143144
}
144145

145146
compileTestKotlin {
146-
kotlinOptions {
147-
jvmTarget = "11"
148-
}
147+
kotlinOptions {
148+
jvmTarget = "11"
149+
}
149150
}
150151

151152
@SuppressWarnings("GrMethodMayBeStatic")
152153
String versionFromTag() {
153-
154-
def headTag = grgit.tag.list().find {
155-
it.commit.getId() == grgit.head().getId()
156-
}
157-
158-
// Uncommitted changes? -> should be SNAPSHOT
159-
// Also watch out for false positives in the CI build
160-
def clean = grgit.status().clean || System.getenv('CI') != null
161-
162-
if (!clean) {
163-
println("Git state is dirty, setting version as snapshot")
164-
}
165-
166-
if (headTag && clean) {
167-
headTag.getName()
168-
} else {
169-
"${grgit.head().id}-SNAPSHOT"
170-
}
154+
def headTag = grgit.tag.list().find {
155+
it.commit.getId() == grgit.head().getId()
156+
}
157+
158+
// Uncommitted changes? -> should be SNAPSHOT
159+
// Also watch out for false positives in the CI build
160+
def clean = grgit.status().clean || System.getenv('CI') != null
161+
162+
if (!clean) {
163+
println("Git state is dirty, setting version as snapshot")
164+
}
165+
166+
if (headTag && clean) {
167+
headTag.getName()
168+
} else {
169+
"${grgit.head().id}-SNAPSHOT"
170+
}
171171
}
172172

173173
//create a simple version file that we will be reading to create appropriate docker tags
174174
void versionTxt() {
175-
new File("$projectDir/VERSION.txt").text = "$project.version\n"
175+
new File("$projectDir/VERSION.txt").text = "$project.version\n"
176176
}
177177

178178
versionTxt()

0 commit comments

Comments
 (0)