-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
141 lines (121 loc) · 2.88 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
plugins {
id "com.jfrog.bintray" version "1.8.0"
id "com.github.spotbugs" version "1.6.1"
}
group 'codes.brick'
version '1.1.2'
apply plugin: 'java'
apply plugin: "checkstyle"
apply plugin: "pmd"
apply plugin: "maven-publish"
sourceCompatibility = 1.9
repositories {
jcenter()
}
ext {
gdxVersion = '1.9.8'
ashleyVersion = '1.7.3'
}
repositories {
mavenCentral()
}
dependencies {
}
checkstyle {
configFile = new File(rootDir, "config/checkstyle/google_checks.xml")
toolVersion = '8.8'
ignoreFailures = true
}
spotbugs {
toolVersion = '3.1.2'
ignoreFailures = true
}
pmd {
toolVersion = '6.1.0'
ignoreFailures = true
}
task sourcesJar(type: Jar, dependsOn: classes) {
classifier = 'sources'
from sourceSets.main.allSource
}
task javadocJar(type: Jar, dependsOn: javadoc) {
classifier = 'javadoc'
from javadoc.destinationDir
}
tasks.withType(Checkstyle) {
reports {
xml.enabled true
html.enabled false
}
}
tasks.withType(com.github.spotbugs.SpotBugsTask) {
reports {
xml.enabled true
html.enabled false
}
}
task wrapper(type: Wrapper) {
gradleVersion = '4.6'
}
dependencies {
compile "com.badlogicgames.gdx:gdx:$gdxVersion"
compile "com.badlogicgames.gdx:gdx-freetype:$gdxVersion"
compile "com.badlogicgames.gdx:gdx-controllers:$gdxVersion"
compile "com.badlogicgames.ashley:ashley:$ashleyVersion"
}
bintray {
user = System.getenv('BINTRAY_USER')
key = System.getenv('BINTRAY_KEY')
pkg {
repo = 'codes.brick'
name = 'common'
userOrg = 'brickcodes'
licenses = ['MIT']
vcsUrl = 'https://github.com/brick-codes/libgdx-common.git'
version {
name = project.version
released = new Date()
vcsTag = project.version
}
}
publish = true
publications = ["CommonPublication"]
}
def pomConfig = {
licenses {
license {
name "MIT"
url "https://opensource.org/licenses/MIT"
distribution "repo"
}
}
developers {
developer {
id "DenialAdams"
name "Richard McCormack"
email "[email protected]"
}
}
scm {
url "https://github.com/brick-codes/libgdx-common"
}
}
publishing {
publications {
CommonPublication(MavenPublication) {
from components.java
artifact sourcesJar
artifact javadocJar
groupId 'codes.brick'
artifactId 'common'
version project.version
pom.withXml {
def root = asNode()
root.appendNode('description', 'utility code for libgdx games')
root.appendNode('name', 'libgdx-common')
root.appendNode('url', 'http://brick.codes')
root.children().last() + pomConfig
}
}
}
}