-
Notifications
You must be signed in to change notification settings - Fork 4
/
build.gradle
56 lines (48 loc) · 1.28 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
plugins {
id 'java'
id 'com.github.johnrengelman.shadow' version '5.2.0'
id 'org.jetbrains.kotlin.jvm' version '1.5.30'
}
compileJava.options.encoding = 'UTF-8'
sourceCompatibility = 1.8
targetCompatibility = 1.8
project.configurations.implementation.canBeResolved = true
archivesBaseName = "ThorQQ"
String allFiles = ""
shadowJar {
configurations = []
classifier = ''
}
repositories {
mavenCentral()
}
dependencies {
implementation 'net.dv8tion:JDA:+'
implementation 'net.mamoe:mirai-core:2.10.0-RC2'
implementation "club.minnced:discord-webhooks:+"
implementation files('/home/shawiizz/Documents/Libraries/ShaGoogleTranslate.jar')
}
task copyToLib(type: Copy) {
into "${buildDir}/output/libs"
from configurations.runtimeClasspath
}
task buildThorQQ() {
for (File f : new File("${buildDir}/output/libs").listFiles())
if(f.getName().endsWith(".jar"))
allFiles += "libs/"+f.getName()+ " "
dependsOn shadowJar
}
task buildThorQQFatJar() {
/*allFiles = ''
dependsOn shadowJar {
configurations = [project.configurations.runtimeClasspath]
classifier = 'fat'
}*/
}
jar {
manifest {
attributes (
'Main-Class': 'com.mohistmc.thor.MohistMC', 'Class-Path': allFiles
)
}
}