forked from miho/JCSG
-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathbuild.gradle
More file actions
104 lines (89 loc) · 2.67 KB
/
build.gradle
File metadata and controls
104 lines (89 loc) · 2.67 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
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
plugins {
id 'eclipse'
id 'java'
id 'java-library'
id 'maven-publish'
id 'signing'
id 'com.diffplug.spotless' version '6.25.0'
}
spotless {
java {
lineEndings = com.diffplug.spotless.LineEnding.UNIX
eclipse('4.26')
removeUnusedImports()
trimTrailingWhitespace()
endWithNewline()
}
}
java {
sourceCompatibility = JavaVersion.VERSION_25
targetCompatibility = JavaVersion.VERSION_25
withJavadocJar()
withSourcesJar()
}
base {
archivesName = "JavaCad"
}
File buildDir = file(".")
Properties props = new Properties()
props.load(new FileInputStream(buildDir.getAbsolutePath() + "/src/main/resources/com/neuronrobotics/javacad/build.properties"))
group = "com.neuronrobotics"
version = props."app.version"
tasks.withType(JavaCompile).configureEach {
options.encoding = 'UTF-8'
options.compilerArgs += ['--enable-preview']
}
repositories {
mavenCentral()
mavenLocal()
maven { url "https://clojars.org/repo" }
}
allprojects {
tasks.withType(Javadoc).configureEach {
options.addStringOption("encoding", "UTF-8")
options.addStringOption('Xdoclint:none', '-quiet')
}
}
dependencies {
testImplementation group: 'junit', name: 'junit', version: '4.0'
implementation 'commons-io:commons-io:2.7'
implementation group: 'com.googlecode.json-simple', name: 'json-simple', version: '1.1'
implementation 'com.google.code.gson:gson:2.8.9'
implementation group: 'eu.mihosoft.vvecmath', name: 'vvecmath', version: '0.4.0'
implementation group: 'javax.vecmath', name: 'vecmath', version: '1.5.2'
implementation 'org.slf4j:slf4j-simple:1.6.1'
implementation group: 'org.apache.xmlgraphics', name: 'batik-all', version: '1.17'
implementation fileTree(dir: 'libs', includes: ['kabeja*.jar'])
implementation group: 'org.locationtech.jts', name: 'jts-core', version: '1.20.0'
implementation 'com.aparapi:aparapi:3.0.2'
implementation 'org.bouncycastle:bcprov-jdk18on:1.80'
implementation 'org.bouncycastle:bcpkix-jdk18on:1.80'
implementation("com.github.madhephaestus:manifold3d:v3.4.1-18")
}
Date buildTimeAndDate = new Date()
ext {
buildDate = new java.text.SimpleDateFormat('yyyy-MM-dd').format(buildTimeAndDate)
buildTime = new java.text.SimpleDateFormat('HH:mm:ss.SSSZ').format(buildTimeAndDate)
}
tasks.withType(Test).configureEach {
jvmArgs '--enable-preview'
}
tasks.withType(JavaExec).configureEach {
jvmArgs '--enable-preview'
}
test {
dependsOn 'spotlessApply'
testLogging {
events "passed", "skipped", "failed", "standardOut", "standardError"
showStandardStreams = true
exceptionFormat = "full"
showExceptions = true
showCauses = true
showStackTraces = true
}
}
javadoc {
if (JavaVersion.current().isJava9Compatible()) {
options.addBooleanOption('html5', true)
}
}