-
Notifications
You must be signed in to change notification settings - Fork 83
/
build.gradle
115 lines (97 loc) · 3.85 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
tasks.named('wrapper') {
gradleVersion = '7.5.1'
distributionUrl = "https://services.gradle.org/distributions/gradle-${gradleVersion}-all.zip"
}
class Developer {
String id
String name
String url
}
ext {
androidBuildToolsVersion = '33.0.0'
androidCompileSdkVersion = 33
androidTargetSdkVersion = 33
assertJVersion = '1.7.1'
gdxVersion = '1.9.8'
robolectricVersion = '4.3_r2-robolectric-0'
developers = [
new Developer(id: 'noblemaster', name: 'Christoph Aschwanden',
url: "http://www.noblemaster.com"),
new Developer(id: 'keesvandieren', name: 'Kees van Dieren',
url: "https://www.teachkidslanguages.com")
]
libraries = [
assertj_core : "org.assertj:assertj-core:1.7.1",
jsr305 : 'com.google.code.findbugs:jsr305:3.0.2',
junit : 'junit:junit:4.12',
libgdx_core : "com.badlogicgames.gdx:gdx:${gdxVersion}",
libgdx_backend_android : "com.badlogicgames.gdx:gdx-backend-android:${gdxVersion}",
libgdx_platform_natives_desktop : "com.badlogicgames.gdx:gdx-platform:${gdxVersion}:natives-desktop",
mockito_core : 'org.mockito:mockito-core:2.7.21',
robovm_rt : "com.mobidevelop.robovm:robovm-rt:$roboVMVersion",
robovm_cocoatouch : "com.mobidevelop.robovm:robovm-cocoatouch:$roboVMVersion",
support_v4 : "com.android.support:support-v4:25.0.0"
]
isReleaseBuild = {
return project.hasProperty("RELEASE")
}
isLocalBuild = {
return project.hasProperty("LOCAL")
}
getLocalRepositoryUrl = {
return project.hasProperty('LOCAL_REPOSITORY_URL') ? LOCAL_REPOSITORY_URL
: 'file://' + new File(System.getProperty('user.home'), '.m2/repository').absolutePath
}
getReleaseRepositoryUrl = {
return project.hasProperty('RELEASE_REPOSITORY_URL') ? RELEASE_REPOSITORY_URL
: "https://oss.sonatype.org/service/local/staging/deploy/maven2/"
}
getSnapshotRepositoryUrl = {
return project.hasProperty('SNAPSHOT_REPOSITORY_URL') ? SNAPSHOT_REPOSITORY_URL
: "https://oss.sonatype.org/content/repositories/snapshots/"
}
getRepositoryUsername = {
return project.hasProperty('NEXUS_USERNAME') ? NEXUS_USERNAME : "$System.env.NEXUS_USERNAME"
}
getRepositoryPassword = {
return project.hasProperty('NEXUS_PASSWORD') ? NEXUS_PASSWORD : "$System.env.NEXUS_PASSWORD"
}
}
buildscript {
ext {
roboVMVersion = '2.3.21'
}
repositories {
mavenCentral()
maven { url "https://plugins.gradle.org/m2/" }
mavenLocal()
google()
maven { url "https://oss.sonatype.org/content/repositories/snapshots/" }
}
dependencies {
classpath "com.android.tools.build:gradle:7.2.2"
classpath "com.mobidevelop.robovm:robovm-gradle-plugin:${roboVMVersion}"
}
}
allprojects {
apply plugin: "eclipse"
repositories {
mavenLocal()
google()
mavenCentral()
maven { url "https://plugins.gradle.org/m2/" }
maven { url "https://oss.sonatype.org/content/repositories/snapshots/" }
maven { url "https://oss.sonatype.org/content/repositories/releases/" }
}
version project.getProperty('version') + (isReleaseBuild() ? "" : "-SNAPSHOT")
tasks.withType(Sign) {
onlyIf { isReleaseBuild() }
}
}
if (JavaVersion.current().isJava8Compatible()) {
allprojects {
tasks.withType(Javadoc) {
options.addStringOption('Xdoclint:none', '-quiet')
}
}
}