-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
54 lines (44 loc) · 1.21 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
apply plugin: 'application'
apply plugin: 'java'
// Version is taken from dslink.json
build {
version = new groovy.json.JsonSlurper().parseText(file('dslink.json').text).version
}
mainClassName = 'org.iot.dsa.dslink.DSLink'
sourceCompatibility = 1.8
targetCompatibility = 1.8
repositories {
mavenLocal()
mavenCentral()
maven {
url 'https://jitpack.io'
}
}
dependencies {
//implementation 'org.iot-dsa:dslink-java-v2-restadapter:1.4.0' //for a locally installed sdk
implementation 'com.github.iot-dsa-v2:dslink-java-v2-restadapter:1.4.1'
implementation 'org.apache.cxf:cxf-rt-rs-client:3.4.2'
}
jar {
manifest {
attributes(
'Automatic-Module-Name' : 'org.iot.dsa.dslink.pi'
)
}
}
applicationDistribution.from(new File(project.projectDir, "/dslink.json"))
distZip {
archiveName project.name + ".zip"
eachFile { file ->
String path = file.relativePath
file.setPath(path.substring(path.indexOf("/")+1,path.length()))
}
}
distTar.enabled = false
run {
args System.getProperty("exec.args", "").split()
workingDir project.buildDir
}
wrapper {
gradleVersion = '6.8'
}