-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.gradle
More file actions
93 lines (73 loc) · 2.6 KB
/
Copy pathbuild.gradle
File metadata and controls
93 lines (73 loc) · 2.6 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
plugins {
id 'java'
id 'org.springframework.boot' version '3.2.1'
id 'io.spring.dependency-management' version '1.1.4'
}
ext.getVersionFromGitTag = { fallbackVersion ->
def gitTag = 'git describe --tags --exact-match HEAD 2>/dev/null)'.execute().text.trim()
def v = !gitTag.isEmpty() && gitTag.startsWith('v') ? gitTag.substring(1) : fallbackVersion
println "Setting project version to: $v"
return v
}
group = 'de.tutum'
version = getVersionFromGitTag('0.1.0-SNAPSHOT')
java {
sourceCompatibility = '21'
targetCompatibility = '21'
toolchain {
languageVersion = JavaLanguageVersion.of(21)
}
}
repositories {
mavenCentral()
maven {
url "https://gitlab.lrz.de/api/v4/groups/190013/-/packages/maven"
credentials(HttpHeaderCredentials) {
name = tutumGitlabUsername // the variable resides in $GRADLE_USER_HOME/gradle.properties
value = tutumGitlabToken // the variable resides in $GRADLE_USER_HOME/gradle.properties
}
authentication {
header(HttpHeaderAuthentication)
}
}
}
def springBootVersion = "3.1.1"
def lombokVersion = "1.18.30"
def grpcVersion = "1.60.1"
def testcontainersVersion = "1.19.0"
dependencies {
implementation "org.springframework.boot:spring-boot-starter-web:${springBootVersion}"
implementation "org.springframework.boot:spring-boot-starter-data-jpa:${springBootVersion}"
implementation "org.springframework.boot:spring-boot-starter-actuator:${springBootVersion}"
implementation 'io.hypersistence:hypersistence-utils-hibernate-62:3.7.0'
implementation 'org.flywaydb:flyway-core'
implementation 'de.tutum:Contracts:0.1.2'
// --- Runtime
runtimeOnly 'org.postgresql:postgresql'
runtimeOnly "io.grpc:grpc-netty-shaded:${grpcVersion}"
// --- Compile
compileOnly "org.projectlombok:lombok:${lombokVersion}"
// --- Annotations
annotationProcessor "org.projectlombok:lombok:${lombokVersion}"
annotationProcessor 'org.hibernate.orm:hibernate-jpamodelgen:6.2.4.Final'
// --- Test Implementation
testImplementation "org.springframework.boot:spring-boot-starter-test:${springBootVersion}"
testImplementation "org.springframework.boot:spring-boot-testcontainers:${springBootVersion}"
testImplementation "org.testcontainers:junit-jupiter:${testcontainersVersion}"
testImplementation "org.testcontainers:postgresql:${testcontainersVersion}"
// --- Test Compile
testCompileOnly "org.projectlombok:lombok:${lombokVersion}"
// --- Test Annotations
testAnnotationProcessor "org.projectlombok:lombok:${lombokVersion}"
}
dependencyManagement {
imports {
mavenBom "org.testcontainers:testcontainers-bom:${testcontainersVersion}"
}
}
jar {
enabled = false
}
test {
useJUnitPlatform()
}