-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
61 lines (54 loc) · 1.54 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
plugins {
id 'org.openjfx.javafxplugin' version '0.0.9'
id 'org.beryx.jlink' version '2.22.0'
}
dependencies {
implementation 'org.fxmisc.richtext:richtextfx:0.10.5'
}
repositories {
mavenCentral()
}
javafx {
version = '14'
modules = ['javafx.controls']
}
version = '5.4.3'
application {
mainModule.set("org.example.richtextfx")
mainClass.set("org.example.richtextfx.JavaKeywordsDemo")
}
jlink {
options = ['--strip-debug', '--compress', '2', '--no-header-files', '--no-man-pages']
launcher {
name = 'java-keywords'
noConsole = true
}
addExtraDependencies("javafx")
jpackage {
jvmArgs = ['-splash:$APPDIR/splash.png']
def currentOs = org.gradle.internal.os.OperatingSystem.current()
def imgType = currentOs.windows ? 'ico' : currentOs.macOsX ? 'icns' : 'png'
icon = "src/main/resources/java.$imgType"
// imageOptions += ['--win-console']
installerOptions += [
'--vendor', 'Acme Corporation',
'--file-associations', 'src/main/resources/associations.properties',
'--app-version', version
]
if (currentOs.windows) {
installerOptions += ['--win-per-user-install', '--win-dir-chooser', '--win-menu']
}
}
/*
customImage {
appModules = ['javafx.base', 'javafx.controls', 'javafx.graphics']
}
*/
}
tasks.jpackageImage.doLast {
copy {
from "src/main/resources"
include "splash.png"
into "build/jpackage/$project.name/app"
}
}