-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.gradle
More file actions
66 lines (53 loc) · 1.72 KB
/
Copy pathbuild.gradle
File metadata and controls
66 lines (53 loc) · 1.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
plugins {
id 'org.springframework.boot' version '2.7.1'
id 'io.spring.dependency-management' version '1.0.12.RELEASE'
id 'java-library'
id 'maven-publish'
}
allprojects {
apply plugin: 'org.springframework.boot'
apply plugin: 'io.spring.dependency-management'
apply plugin: 'java-library'
apply plugin: 'maven-publish'
group 'com.demkom58'
version '0.5-SNAPSHOT'
bootJar.enabled = false
jar.enabled = true
compileJava.options.encoding = "UTF-8"
compileTestJava.options.encoding = "UTF-8"
compileJava {
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
}
dependencies {
testImplementation group: 'org.junit.jupiter', name: 'junit-jupiter-api'
testImplementation group: 'org.junit.jupiter', name: 'junit-jupiter-engine'
testImplementation group: 'org.mockito', name: 'mockito-junit-jupiter'
}
test {
useJUnitPlatform()
}
task sourceJar(type: Jar) {
from sourceSets.main.allJava
archiveClassifier = "sources"
}
task install(dependsOn: 'publishToMavenLocal')
publishing {
publications {
maven(MavenPublication) {
from components.java
artifact sourceJar
}
}
repositories {
maven {
name = "GitHubPackages"
url = uri("https://maven.pkg.github.com/demkom58/springram")
credentials {
username = project.findProperty("gpr.user") ?: System.getenv("USERNAME")
password = project.findProperty("gpr.key") ?: System.getenv("TOKEN")
}
}
}
}
}