-
Notifications
You must be signed in to change notification settings - Fork 7
/
build.gradle
94 lines (78 loc) · 2.05 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 'java'
id 'application'
id 'antlr'
id "com.github.johnrengelman.shadow" version "7.1.2"
id 'com.github.hierynomus.license' version '0.16.1'
id "org.ajoberstar.grgit" version "1.7.2"
}
group 'edu.kit.kastel.formal'
version '1.1.0'
task versionFile() {
def resourcesDir = sourceSets.main.output.resourcesDir
outputs.dir resourcesDir
doFirst {
resourcesDir.mkdirs()
new File(resourcesDir, "VERSION").text = "$version (${grgit.head().abbreviatedId})"
print( "$resourcesDir/VERSION created.")
}
}
compileJava.configure {
dependsOn versionFile
}
repositories {
mavenCentral()
}
jar {
manifest {
attributes "Main-Class": "edu.kit.kastel.formal.mimaflux.MimaFlux"
}
}
java {
toolchain {
languageVersion = JavaLanguageVersion.of(16)
}
}
application {
mainClass = "edu.kit.kastel.formal.mimaflux.MimaFlux"
}
shadowJar {
dependsOn versionFile
dependencies {
exclude(dependency('org.antlr:antlr4:.*'))
exclude(dependency('com.ibm.icu:.*:.*'))
exclude(dependency('org.antlr:ST4:.*'))
}
}
//configurations {
// implementation {
// extendsFrom = extendsFrom.findAll { it != configurations.antlr }
// }
//}
dependencies {
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.8.1'
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:5.8.1'
// Runtime only needs antlr4-runtime, not the whole antlr4.
implementation 'org.antlr:antlr4-runtime:4.7.1'
// Customise antlr4 version, for buildscript
antlr 'org.antlr:antlr4:4.7.1'
implementation 'com.beust:jcommander:1.82'
implementation 'org.kordamp.ikonli:ikonli-swing:12.3.1'
implementation 'org.kordamp.ikonli:ikonli-codicons-pack:12.3.1'
}
generateGrammarSource {
maxHeapSize = "64m"
arguments += ["-visitor", "-no-listener"]
}
test {
useJUnitPlatform()
}
license {
header file("HEADER")
include "**/*.java"
include "**/*.g4"
mapping {
java = "SLASHSTAR_STYLE"
g4 = "SLASHSTAR_STYLE"
}
}