-
Notifications
You must be signed in to change notification settings - Fork 15
/
build.gradle
164 lines (140 loc) · 5.43 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
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
import java.text.SimpleDateFormat
plugins {
id 'idea'
id 'java-library'
id 'com.google.osdetector' version '1.7.0'
id 'org.javamodularity.moduleplugin' version '1.8.7'
id 'org.beryx.jlink' version '2.23.2'
id 'net.nemerosa.versioning' version '2.14.0'
id 'biz.aQute.bnd.builder' version '5.3.0'
}
apply plugin: 'biz.aQute.bnd.builder'
sourceCompatibility = '16'
description = 'A little demo of TilesFx in combination with other libraries'
mainClassName = '$moduleName/eu.hansolo.tilesfxdemo.DemoLauncher'
Date buildTimeAndDate = new Date()
ext {
buildDate = new SimpleDateFormat('yyyy-MM-dd').format(buildTimeAndDate)
buildTime = new SimpleDateFormat('HH:mm:ss.SSSZ').format(buildTimeAndDate)
platform = osdetector.os == 'osx' ? 'mac' : osdetector.os == 'windows' ? 'win' : osdetector.os
}
repositories {
flatDir {
dir 'libs'
}
mavenCentral()
}
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation "org.openjfx:javafx-base:16:$platform"
implementation "org.openjfx:javafx-graphics:16:$platform"
implementation "org.openjfx:javafx-controls:16:$platform"
implementation "org.openjfx:javafx-swing:16:$platform"
implementation "org.openjfx:javafx-web:16:$platform"
implementation "org.openjfx:javafx-media:16:$platform"
implementation "org.openjfx:javafx-fxml:16:$platform"
implementation ('eu.hansolo:tilesfx:16.0.3') {
exclude group: 'org.openjfx'
}
implementation ('eu.hansolo:Medusa:11.5') {
exclude group: 'org.openjfx'
}
implementation ('eu.hansolo:regulators:11.7') {
exclude group: 'org.openjfx'
}
implementation 'org.kordamp.ikonli:ikonli-core:11.5.0'
implementation 'org.kordamp.ikonli:ikonli-javafx:11.5.0'
implementation 'org.kordamp.ikonli:ikonli-material-pack:11.5.0'
implementation 'org.kordamp.ikonli:ikonli-materialdesign-pack:11.5.0'
implementation 'org.kordamp.ikonli:ikonli-fontawesome-pack:11.5.0'
implementation 'org.kordamp.ikonli:ikonli-weathericons-pack:11.5.0'
implementation 'com.googlecode.json-simple:json-simple:1.1.1'
implementation 'com.github.almasb:fxgl:11.16'
}
// start the demo from gradle
task Main(type: JavaExec) {
main = "eu.hansolo.tilesfxdemo.MainLauncher"
classpath = sourceSets.main.runtimeClasspath
}
task Demo(type: JavaExec) {
main = "eu.hansolo.tilesfxdemo.DemoLauncher"
classpath = sourceSets.main.runtimeClasspath
}
task Overview(type: JavaExec) {
main = "eu.hansolo.tilesfxdemo.OverviewLauncher"
classpath = sourceSets.main.runtimeClasspath
}
task Countdown(type: JavaExec) {
main = "eu.hansolo.tilesfxdemo.CountdownLauncher"
classpath = sourceSets.main.runtimeClasspath
}
task Interactive(type: JavaExec) {
main = "eu.hansolo.tilesfxdemo.InteractiveDemoLauncher"
classpath = sourceSets.main.runtimeClasspath
}
task Calendar(type: JavaExec) {
main = "eu.hansolo.tilesfxdemo.CalendarTileDemoLauncher"
classpath = sourceSets.main.runtimeClasspath
}
task Matrix(type: JavaExec) {
main = "eu.hansolo.tilesfxdemo.MatrixTileDemoLauncher"
classpath = sourceSets.main.runtimeClasspath
}
task Control(type: JavaExec) {
main = "eu.hansolo.tilesfxdemo.ControlDemoLauncher"
classpath = sourceSets.main.runtimeClasspath
}
task Misc(type: JavaExec) {
main = "eu.hansolo.tilesfxdemo.MiscDemoLauncher"
classpath = sourceSets.main.runtimeClasspath
}
task Layout(type: JavaExec) {
main = "eu.hansolo.tilesfxdemo.LayoutDemoLauncher"
classpath = sourceSets.main.runtimeClasspath
}
task WorldmapTile(type: JavaExec) {
main = "eu.hansolo.tilesfxdemo.WorldmapTileDemoLauncher"
classpath = sourceSets.main.runtimeClasspath
}
task TouchSlider(type: JavaExec) {
main = "eu.hansolo.tilesfxdemo.TouchSliderDemoLauncher"
classpath = sourceSets.main.runtimeClasspath
}
repositories {
mavenCentral()
//jcenter()
}
jar {
manifest {
attributes(
'Built-By' : System.properties['user.name'],
'Created-By' : System.properties['java.version'] + " (" + System.properties['java.vendor'] + " " + System.properties['java.vm.version'] + ")",
'Build-Date' : project.buildDate,
'Build-Time' : project.buildTime,
'Build-Revision' : versioning.info.commit,
'Specification-Title' : project.name,
'Specification-Version' : project.version,
'Implementation-Title' : project.name,
'Implementation-Version': project.version,
'Bundle-Name' : project.name,
'Bundle-License' : 'https://www.apache.org/licenses/LICENSE-2.0;description=Apache License Version 2.0;link=https://www.eclipse.org/legal/eplfaq.php',
'Bundle-Description' : description,
'Bundle-SymbolicName' : 'eu.hansolo',
'Export-Package' : 'eu.hansolo.tilesfxdemo',
'Class-Path' : 'tilesfxdemo-16.0.jar',
'Main-Class' : 'eu.hansolo.tilesfxdemo.DemoLauncher'
)
}
}
jlink {
options = ['--strip-debug', '--compress', '2', '--no-header-files', '--no-man-pages']
launcher {
name = 'eu.hansolo.tilesfxdemo'
}
}
// Fix problems with loading resources
sourceSets {
main {
output.setResourcesDir(java.outputDir)
}
}