-
-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathbuild.gradle
85 lines (71 loc) · 2.16 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
buildscript {
repositories {
maven {
url "https://plugins.gradle.org/m2/"
}
}
dependencies {
classpath "gradle.plugin.com.github.sherter.google-java-format:google-java-format-gradle-plugin:0.9"
classpath 'com.adarshr:gradle-test-logger-plugin:3.0.0'
}
}
apply plugin: 'java-library'
apply plugin: 'maven'
apply plugin: 'maven-publish'
apply plugin: 'signing'
apply plugin: 'jacoco'
apply plugin: "com.github.sherter.google-java-format"
apply from: 'gradle/release.gradle'
apply plugin: 'com.adarshr.test-logger'
repositories {
mavenCentral()
}
version = VERSION
group = GROUP_ID
dependencies {
implementation 'ch.qos.logback:logback-classic:1.2.6'
implementation 'ch.qos.logback:logback-core:1.2.6'
implementation 'org.slf4j:slf4j-api:1.7.32'
implementation 'com.kohlschutter.junixsocket:junixsocket-common:2.4.0'
implementation 'com.kohlschutter.junixsocket:junixsocket-native-common:2.4.0'
api 'com.google.code.gson:gson:2.8.8'
implementation 'org.reflections:reflections:0.10.2'
implementation 'com.google.guava:guava:31.0.1-jre'
implementation 'commons-io:commons-io:2.4'
testImplementation 'junit:junit:4.13.2'
}
task copyLib(type: Copy) {
from "${project.buildDir}/libs/jrpclightning-${version}-with-dependencies.jar" into '/home/vincent/Github/LNQrcode/devlib'
}
test {
testLogging {
showStandardStreams = true
}
reports {
junitXml.enabled = true
html.enabled = true
}
finalizedBy jacocoTestReport // report is always generated after tests run
}
jacocoTestReport {
reports {
xml.enabled true
html.enabled false
}
dependsOn test // tests are required to run before generating the report
}
jar {
archiveVersion.set(VERSION as String)
inputs.property("moduleName", MODULE_NAME)
manifest {
attributes 'Automatic-Module-Name': MODULE_NAME
}
}
task jarWithDependencies(type: Jar) {
archiveVersion.set(VERSION as String)
archiveClassifier.set('with-dependencies')
from {
configurations.runtimeClasspath.collect { it.isDirectory() ? it : zipTree(it) }
}
with jar
}