-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathbuild.gradle
75 lines (65 loc) · 1.51 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
plugins {
id 'java'
id 'maven-publish'
id 'com.github.johnrengelman.shadow' version '7.1.2'
id "com.diffplug.spotless" version "6.6.1"
id "jacoco"
}
repositories {
mavenCentral()
mavenLocal()
}
dependencies {
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.8.2'
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:5.8.2'
implementation 'org.eclipse.paho:org.eclipse.paho.client.mqttv3:1.2.5'
compileOnly 'org.projectlombok:lombok:1.18.24'
annotationProcessor 'org.projectlombok:lombok:1.18.24'
}
group = 'io.github.dschanoeh'
version = '0.2.0'
sourceCompatibility = '1.8'
jacocoTestReport {
dependsOn test
}
test {
useJUnitPlatform()
finalizedBy jacocoTestReport
}
jacocoTestReport {
reports {
xml.required = true
html.required = true
}
}
shadowJar {
archiveVersion = project.getVersion()
archiveClassifier = ''
archiveBaseName = 'homie-java'
}
spotless {
java {
indentWithSpaces()
trimTrailingWhitespace()
}
}
publishing {
publications {
homieJava(MavenPublication){
from components.java
}
}
repositories {
maven {
name = "GitHubPackages"
url = "https://maven.pkg.github.com/dschanoeh/homie-java"
credentials {
username = System.getenv("GITHUB_ACTOR")
password = System.getenv("GITHUB_TOKEN")
}
}
}
}
tasks.withType(JavaCompile) {
options.encoding = 'UTF-8'
}