-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.gradle
More file actions
95 lines (75 loc) · 2.72 KB
/
build.gradle
File metadata and controls
95 lines (75 loc) · 2.72 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
plugins {
id 'java'
id 'application'
id 'jsonschema2pojo'
id 'com.github.jk1.dependency-license-report' version '2.4'
id 'com.github.seanrl.jaxb' version '2.5.4'
}
group = 'com.github.stuartraetaylor.punkapiexport'
version = '0.3.0'
java {
toolchain {
languageVersion = JavaLanguageVersion.of(21)
}
}
repositories {
mavenLocal()
mavenCentral()
}
String jaxbVersion = '4.0.+'
String jacksonVersion = '2.16.+'
dependencies {
implementation group: 'org.apache.logging.log4j', name: 'log4j-core', version: '2.22.+'
implementation group: 'org.apache.commons', name: 'commons-lang3', version: '3.14.+'
implementation group: 'org.apache.httpcomponents', name: 'httpclient', version: '4.5.+'
implementation group: 'commons-cli', name: 'commons-cli', version: '1.6.+'
implementation group: 'com.fasterxml.jackson.core', name: 'jackson-core', version: jacksonVersion
implementation group: 'com.fasterxml.jackson.core', name: 'jackson-databind', version: jacksonVersion
implementation group: 'com.fasterxml.jackson.core', name: 'jackson-annotations', version: jacksonVersion
implementation group: 'jakarta.xml.bind', name: 'jakarta.xml.bind-api', version: jaxbVersion
runtimeOnly group: 'com.sun.xml.bind', name: 'jaxb-impl', version: jaxbVersion
jaxb group: 'org.glassfish.jaxb', name: 'jaxb-xjc', version: jaxbVersion
jaxb group: 'org.glassfish.jaxb', name: 'jaxb-runtime', version: jaxbVersion
}
defaultTasks 'build'
wrapper {
distributionType = Wrapper.DistributionType.BIN
gradleVersion = '8.5'
}
jar {
archiveBaseName = 'pinkapiexport'
}
processResources {
doLast {
ant.propertyfile(file: "${project.sourceSets.main.output.resourcesDir}/version-info.properties") {
entry(key: 'version', value: project.version)
}
}
}
application {
mainClass = "${group}.Main"
}
jsonSchema2Pojo {
source = files('submodules/punkapi-db/spec/schema.json')
targetDirectory = file("${project.buildDir}/generated-sources/js2p")
removeOldOutput = false
targetPackage = "${group}.punkapi.model"
classNamePrefix = 'Punk'
includeGetters = true
includeSetters = true
useBigDecimals = true
}
jaxb {
xsdDir = "${project.projectDir}/submodules/beerxml-schema/historical/BeerXML v1/"
xjc {
generatePackage = "${group}.beerxml.model"
}
}
// Add generated JAXB classes to source set.
project.sourceSets.main.java.srcDirs += [ file(jaxb.xjc.destinationDir) ]
compileJava.dependsOn 'xjc'
xjc.dependsOn 'processResources'
licenseReport {
renderers = [ new com.github.jk1.license.render.SimpleHtmlReportRenderer('license-report.html') ]
filters = [ new com.github.jk1.license.filter.LicenseBundleNormalizer() ]
}