-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
88 lines (75 loc) · 3 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
plugins {
id 'java'
id 'application'
id 'io.freefair.lombok' version '5.2.1'
id "com.github.johnrengelman.shadow" version "7.0.0"
}
def projectName = 'DemoBot' // Project Name
def projectVersion = '1.0.0' // Project Version
// ADD YOURSELF AS A NEW LINE IF YOU WANT YOUR OWN BUILD TASK GENERATED
// ======================== WINDOWS =============================
registerCustomOutputTask('Psycho', 'C://Users/brian/Desktop/DiscordBotTesting')
// ========================== UNIX ==============================
registerCustomOutputTaskUnix('PsychoLT', '/Users/brianfopiano/Desktop/REMOTES/Bots/DemoBot')
// ==============================================================
group 'com.volmit'
version = projectVersion // Set the project version
application {
mainClass = 'com.volmit.demobot.Demo'
}
repositories {
mavenCentral()
maven { url = uri("https://m2.chew.pro/snapshots") }
maven { url "https://arcanearts.jfrog.io/artifactory/archives" }
maven { url "https://dl.cloudsmith.io/public/arcane/archive/maven/" }
mavenLocal()
}
dependencies {
// Core dependencies
compileOnly 'org.projectlombok:lombok:1.18.24'
annotationProcessor 'org.projectlombok:lombok:1.18.24'
//Discord JDA stuff
implementation 'pw.chew:jda-chewtils:2.0-SNAPSHOT'
implementation 'net.dv8tion:JDA:5.0.0-beta.12'
//My things
implementation 'org.slf4j:slf4j-api:2.0.3'
implementation 'org.slf4j:slf4j-simple:2.0.3'
implementation 'org.jsoup:jsoup:1.15.3'
implementation 'redis.clients:jedis:4.3.1'
implementation 'commons-io:commons-io:2.11.0'
//Cancer
// implementation 'art.arcane:Amulet:23.5.1' // Issue with " Records requires ASM8 "
implementation 'com.github.ArcaneArts:Quill:1.1.8'
annotationProcessor 'systems.manifold:manifold-ext:2023.1.10'
testAnnotationProcessor 'systems.manifold:manifold-ext:2023.1.10'
implementation 'systems.manifold:manifold-rt:2023.1.10'
// Dynamically Loaded
implementation 'com.googlecode.concurrentlinkedhashmap:concurrentlinkedhashmap-lru:1.4.2'
implementation 'com.google.code.gson:gson:2.10'
}
shadowJar {
archiveClassifier.set('')
minimize {
// Add the necessary packages and classes to exclude from minimization
exclude(dependency('org.slf4j:slf4j-api'))
exclude(dependency('org.slf4j:slf4j-simple'))
}
configurations = [project.configurations.runtimeClasspath] // Change this line
archiveFileName = "${projectName}-${projectVersion}.jar"
}
// Custom Output Task for Windows
def registerCustomOutputTask(name, location) {
tasks.register("buildTo${name}", Copy) {
dependsOn shadowJar
from shadowJar.archiveFile.get()
into location
}
}
// Custom Output Task for Unix
def registerCustomOutputTaskUnix(name, location) {
tasks.register("buildTo${name}", Copy) {
dependsOn shadowJar
from shadowJar.archiveFile.get()
into location
}
}