-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
94 lines (76 loc) · 2.64 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
plugins {
id 'net.ltgt.errorprone' version '0.0.16'
}
allprojects {
group = 'nl.weeaboo.gdx-styledtext'
version = '5.1.0'
repositories {
mavenCentral()
}
}
ext.errorProneVersion = '2.3.3'
subprojects {
apply plugin: 'java'
apply plugin: 'jacoco'
apply plugin: 'eclipse'
apply plugin: 'idea'
ext {
gdxVersion = '1.9.14'
junitVersion = '4.12'
gdxTestVersion = '2.0.2'
guavaVersion = '20.0';
}
sourceCompatibility = JavaVersion.VERSION_1_6
targetCompatibility = JavaVersion.VERSION_1_7
tasks.withType(JavaCompile) {
options.encoding = 'UTF-8'
}
dependencies {
// ErrorProne annotations
compileOnly "com.google.errorprone:error_prone_annotations:${rootProject.ext.errorProneVersion}"
// JSR305 annotations (nullable, etc.)
compileOnly "com.google.code.findbugs:jsr305:3.0.1"
testCompile "com.google.guava:guava-testlib:$guavaVersion"
testCompile "junit:junit:$junitVersion"
testCompile "nl.weeaboo.gdx-test:gdx-test-core:$gdxTestVersion"
testCompile "com.badlogicgames.gdx:gdx-backend-lwjgl3:$gdxVersion"
testRuntime "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-desktop"
testRuntime "com.badlogicgames.gdx:gdx-freetype-platform:$gdxVersion:natives-desktop"
}
test {
// Change temp dir (default doesn't work in GitHub actions when running on Windows)
systemProperty 'java.io.tmpdir', file("$buildDir/tmp")
testLogging {
// showStandardStreams true
exceptionFormat = 'full'
}
def uiTest = project.hasProperty('uiTest')
inputs.property('uiTest', uiTest) // Re-execute task if uiTest property changes
useJUnit {
if (!uiTest) {
// Exclude UI tests by default
excludeCategories 'nl.weeaboo.gdx.test.junit.GdxUiTest'
}
}
}
jacocoTestReport {
reports {
xml.enabled true
}
}
// ErrorProne compiler isn't compatible with Java 6, so check that the current JVM uses at least Java 7
if (JavaVersion.current().isJava7Compatible()) {
apply from: rootProject.file('errorprone.gradle')
}
}
project(":styledtext-api") {
project.apply from: rootProject.file('publish.gradle')
}
project(":styledtext-impl") {
dependencies {
compile project(':styledtext-api')
compile "com.badlogicgames.gdx:gdx:$gdxVersion"
compile "com.badlogicgames.gdx:gdx-freetype:$gdxVersion"
}
project.apply from: rootProject.file('publish.gradle')
}