-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathbuild.gradle
66 lines (57 loc) · 1.62 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
plugins {
id 'java'
id 'jacoco'
id 'maven'
}
group 'org.iotlabs'
version '0.0.2'
sourceCompatibility = 1.8
repositories {
mavenCentral()
maven {
url "https://repo.eclipse.org/content/repositories/paho-snapshots/"
}
// for Iot Labs repository
maven {
url "http://13.76.209.35:8081/nexus/content/repositories/dev/"
}
}
dependencies {
testCompile group: 'junit', name: 'junit', version: '4.11'
compile group: 'org.apache.logging.log4j', name: 'log4j-api', version: '2.7'
compile group: 'org.apache.logging.log4j', name: 'log4j-core', version: '2.7'
compile 'org.eclipse.paho:org.eclipse.paho.client.mqttv3:1.0.2'
compile 'com.google.code.gson:gson:2.7'
}
task makejar (type: Jar) {
destinationDir = file("$rootDir/")
from { configurations.compile.collect { it.isDirectory() ? it : zipTree(it) } }
with jar
}
uploadArchives {
if (project.hasProperty("mavenUser")) {
repositories {
mavenDeployer {
repository(url: "http://13.76.209.35:8081/nexus/content/repositories/dev/") {
authentication(userName: "$mavenUser", password: "$mavenPassword")
}
pom.version = "${project.version}"
pom.artifactId = "${project.name}"
pom.groupId = "org.iotlabs"
}
}
}
}
jacoco {
toolVersion = "0.7.6.201602180812"
}
jacocoTestReport {
group = "Reporting"
description = "Generate Jacoco coverage reports after running tests."
reports {
xml{
enabled true
}
}
}
check.dependsOn jacocoTestReport