forked from controlsfx/controlsfx
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
87 lines (73 loc) · 2.73 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
plugins {
id 'org.openjfx.javafxplugin' version '0.0.13' apply false
id 'io.github.gradle-nexus.publish-plugin' version '1.1.0'
}
ext.java9Args = [
// For various behaviors across controls
"--add-exports=javafx.controls/com.sun.javafx.scene.control.behavior=org.controlsfx.controls",
// For ReadOnlyUnbackedObservableList across files
"--add-exports=javafx.controls/com.sun.javafx.scene.control=org.controlsfx.controls",
// For EventHandlerManager in AutoCompletionBinding
"--add-exports=javafx.base/com.sun.javafx.event=org.controlsfx.controls",
// For MappingChange, NonIterableChange across files
"--add-exports=javafx.base/com.sun.javafx.collections=org.controlsfx.controls",
//For SpreadsheetView
"--add-exports=javafx.controls/com.sun.javafx.scene.control.behavior.TableViewBehavior=org.controlsfx.controls",
//For SpreadsheetView
"--add-exports=javafx.base/com.sun.javafx.event.EventHandlerManager=org.controlsfx.controls"
]
ext.java9RuntimeArgs = [
// For accessing getChildren in ImplUtils
"--add-opens=javafx.graphics/javafx.scene=org.controlsfx.controls"
]
subprojects {
apply plugin: 'java'
apply plugin: 'org.openjfx.javafxplugin'
apply from : '../mavenPublish.gradle'
sourceCompatibility = '11'
targetCompatibility = '11'
repositories {
mavenCentral()
}
compileJava {
options.encoding = "UTF-8"
options.incremental = true
}
javadoc {
def javaVersion = JavaVersion.current().majorVersion
if (JavaVersion.current().java11Compatible) {
options.links("https://openjfx.io/javadoc/"+ javaVersion)
options.links("https://docs.oracle.com/en/java/javase/" + javaVersion + "/docs/api")
} else {
options.links("https://docs.oracle.com/javase/" + javaVersion + "/docs/api")
}
}
task sourceJar(type: Jar) {
from sourceSets.main.java
from sourceSets.main.resources
archiveClassifier.set('sources')
}
task javadocJar(type: Jar) {
dependsOn javadoc
from javadoc.destinationDir
archiveClassifier.set('javadoc')
}
artifacts {
archives sourceJar
archives javadocJar
}
// Do not publish Gradle modules
tasks.withType(GenerateModuleMetadata) {
enabled = false
}
}
// nexus publish plugin needs this
version = controlsfx_version
nexusPublishing {
repositories {
sonatype {
username = project.hasProperty('sonatypeUsername') ? project.property('sonatypeUsername') : ''
password = project.hasProperty('sonatypePassword') ? project.property('sonatypePassword') : ''
}
}
}