This repository has been archived by the owner on Feb 23, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
79 lines (65 loc) · 1.72 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
plugins {
id 'java'
id 'org.openjfx.javafxplugin' version '0.0.13'
id 'edu.sc.seis.launch4j' version '3.0.0'
id 'com.github.johnrengelman.shadow' version '7.1.0'
}
group "${project_group}"
version "${project_version}"
sourceCompatibility = '17'
targetCompatibility = '17'
tasks.withType(JavaCompile).configureEach {
options.encoding = 'UTF-8'
}
javafx {
version = '20'
modules = ['javafx.controls', 'javafx.web', 'javafx.swing']
}
repositories {
mavenCentral()
maven {
name 'Litarvan Repo'
url 'https://litarvan.github.io/maven'
}
}
dependencies {
//Logging
implementation "ch.qos.logback:logback-classic:1.4.7"
implementation "org.slf4j:slf4j-api:2.0.7"
//Utilities
implementation "com.google.guava:guava:31.1-jre"
implementation "org.jetbrains:annotations:24.0.0"
implementation "com.google.code.gson:gson:2.10.1"
//Web
implementation "com.squareup.retrofit2:retrofit:2.9.0"
//Auth
implementation 'fr.litarvan:openauth:1.1.6'
}
compileJava {
options.encoding = "UTF-8"
}
shadowJar {
manifest {
attributes 'Main-Class': "${project_main_class}"
attributes 'Description': "${build_description}"
}
archiveClassifier.set('')
mergeServiceFiles()
}
//Only build shadowJar
build.dependsOn(shadowJar)
jar.enabled = false
tasks.register('runLauncher', JavaExec) {
dependsOn build
doFirst {
File runDir = new File("./run")
if (!runDir.exists()) {
runDir.mkdirs()
}
workingDir = runDir
}
mainClass.set("${project_main_class}")
classpath = files(shadowJar.archiveFile)
args '-launcher:dev' // program arguments go here
}
apply from: 'dist/distribute.gradle'