-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
86 lines (73 loc) · 1.95 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
plugins {
id 'java'
id 'distribution'
id 'org.springframework.boot' version '3.4.1'
id 'io.spring.dependency-management' version '1.1.7'
id 'org.graalvm.buildtools.native' version '0.10.4'
id 'org.cyclonedx.bom' version '1.10.0'
}
java {
toolchain {
languageVersion = JavaLanguageVersion.of(23)
}
}
repositories {
mavenCentral()
}
ext {
set('springShellVersion', "3.4.0")
}
dependencies {
implementation platform("org.springframework.shell:spring-shell-dependencies:${springShellVersion}")
implementation 'org.springframework.boot:spring-boot-starter-validation'
implementation 'org.springframework.shell:spring-shell-starter'
testImplementation 'org.springframework.boot:spring-boot-starter-test'
testImplementation 'org.springframework.shell:spring-shell-starter-test'
testRuntimeOnly 'org.junit.platform:junit-platform-launcher'
}
springBoot {
buildInfo()
}
graalvmNative {
binaries {
main {
imageName = "arconia"
}
}
}
tasks.named('test') {
useJUnitPlatform()
}
tasks.named('cyclonedxBom') {
includeConfigs = ["runtimeClasspath"]
outputFormat = "json"
projectType = "application"
schemaVersion = "1.6"
}
distributions {
main {
contents {
from("$buildDir/native/nativeCompile") {
into 'bin'
include 'arconia', 'arconia.exe'
}
from("$buildDir/reports") {
include 'application.cdx.json'
rename { 'sbom.cdx.json' }
}
from(rootDir) {
include 'LICENSE', 'README.md'
}
}
}
}
tasks.named('distZip') {
def archiveName = gradle.startParameter.projectProperties['archiveName'] ?: "arconia-${project.version}.zip"
onlyIf {
gradle.startParameter.taskNames.contains("distZip")
}
archiveFileName = "${archiveName}"
}
tasks.named('distTar') {
enabled = false
}