-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.gradle
More file actions
55 lines (46 loc) · 1.78 KB
/
build.gradle
File metadata and controls
55 lines (46 loc) · 1.78 KB
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
plugins {
id 'java'
id 'application'
id "org.openjfx.javafxplugin" version "0.0.10"
id "io.freefair.lombok" version "6.3.0"
id 'org.beryx.runtime' version '1.12.7'
id "com.github.johnrengelman.shadow" version "7.1.0"
}
repositories {
mavenCentral()
}
dependencies {
implementation 'io.github.palexdev:materialfx:11.12.0'
implementation 'commons-validator:commons-validator:1.7'
implementation 'com.squareup.okhttp3:okhttp:4.9.3'
implementation 'com.fasterxml.jackson.core:jackson-databind:2.13.0'
}
javafx {
version = "17"
modules = ['javafx.controls', 'javafx.fxml', 'javafx.graphics', 'javafx.base', 'javafx.media']
}
mainClassName = "me.darkboy.Launcher"
runtime {
options = ['--strip-debug', '--compress', '2', '--no-header-files', '--no-man-pages']
launcher {
noConsole = true
}
jpackage {
// Uncomment and adjust the following line if your runtime task is configured to generate images for multiple platforms
// targetPlatformName = "mac"
def currentOs = org.gradle.internal.os.OperatingSystem.current()
def imgType = currentOs.windows ? 'ico' : currentOs.macOsX ? 'icns' : 'png'
imageOptions += ['--icon', "src/main/resources/me/darkboy/assets/logo.$imgType"]
installerOptions += ['--resource-dir', "src/main/resources"]
installerOptions += ['--vendor', 'FakeException']
if(currentOs.windows) {
installerOptions += ['--win-per-user-install', '--win-dir-chooser', '--win-menu', '--win-shortcut']
}
else if (currentOs.linux) {
installerOptions += ['--linux-package-name', 'snowy','--linux-shortcut']
}
else if (currentOs.macOsX) {
installerOptions += ['--mac-package-name', 'snowy']
}
}
}