-
Notifications
You must be signed in to change notification settings - Fork 16
/
build.gradle
73 lines (62 loc) · 1.72 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
plugins {
id 'java'
id 'jacoco'
id 'application'
}
group 'security'
version '1.0-SNAPSHOT'
repositories {
mavenCentral()
}
// https://www.baeldung.com/gradle-sourcecompatiblity-vs-targetcompatibility
java {
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
}
dependencies {
implementation 'junit:junit:4.13.1'
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.8.1'
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:5.8.1'
// https://mvnrepository.com/artifact/commons-io/commons-io
implementation 'commons-io:commons-io:2.14.0'
// or the latest version available
implementation 'org.apache.logging.log4j:log4j-core:2.19.0'
}
// Commenting because it doesn't work well on TravisCI
test {
testLogging {
// Make sure output from
// standard out or error is shown
// in Gradle output.
showStandardStreams = true
}
}
// This library was built for Java 8 so it can be imported into Android as well.
// If you want to use a later version of Java, this should help point what to tweak.
gradle.projectsEvaluated {
tasks.withType(JavaCompile).tap {
configureEach {
options.compilerArgs << "-Xlint:deprecation,unchecked"
}
}
}
jacocoTestReport {
reports {
xml.required=true
html.required=true
}
}
check.dependsOn jacocoTestReport
application {
mainClass.set(project.findProperty("chooseRole").toString())
}
// To create the JAR file with 'gradlew jar'
tasks.named('jar') {
archiveFileName = "crypto.jar"
manifest {
attributes(
'Implementation-Title': project.name,
'Implementation-Version': project.version
)
}
}