1
1
plugins {
2
- id " com.github.hierynomus.license" version " 0.11.0"
2
+ id ' java-library'
3
+ id ' jacoco'
4
+ id ' signing'
5
+ id ' maven-publish'
6
+ id " com.github.hierynomus.license" version " 0.16.1"
3
7
}
4
8
5
- apply plugin : ' java'
6
- apply plugin : ' maven'
7
- apply plugin : ' signing'
8
- apply plugin : ' idea'
9
- apply plugin : ' eclipse'
10
- apply plugin : ' license'
11
- apply plugin : ' jacoco'
12
- apply plugin : ' maven-publish'
13
-
14
9
group = ' com.tokbox'
15
10
archivesBaseName = ' opentok-server-sdk'
16
11
version = ' 4.6.0'
17
12
13
+ sourceCompatibility = " 1.8"
14
+ targetCompatibility = " 1.8"
15
+
16
+ repositories {
17
+ mavenCentral()
18
+ }
19
+
20
+ dependencies {
21
+ testImplementation ' junit:junit:4.13.2'
22
+ testImplementation ' com.github.tomakehurst:wiremock:1.58'
23
+ implementation ' commons-lang:commons-lang:2.6'
24
+ implementation ' commons-validator:commons-validator:1.7'
25
+ implementation ' org.asynchttpclient:async-http-client:2.12.3'
26
+ implementation ' com.fasterxml.jackson.core:jackson-databind:2.13.2.2'
27
+ implementation ' commons-codec:commons-codec:1.15'
28
+ implementation ' org.bitbucket.b_c:jose4j:0.7.11'
29
+ }
30
+
31
+ task sourcesJar (type : Jar ) {
32
+ archiveClassifier. set(" sources" )
33
+ from sourceSets. main. allSource
34
+ }
35
+
18
36
task javadocJar (type : Jar ) {
19
37
archiveClassifier. set(" javadoc" )
20
38
from javadoc
@@ -29,35 +47,16 @@ javadoc {
29
47
}
30
48
}
31
49
50
+ jacoco {
51
+ toolVersion = " 0.8.8"
52
+ }
32
53
jacocoTestReport {
33
54
reports {
34
- xml. enabled true
35
- html. enabled false
55
+ xml. getRequired() . set( true )
56
+ html. getRequired() . set( true )
36
57
}
37
58
}
38
-
39
- task sourcesJar (type : Jar ) {
40
- archiveClassifier. set(" sources" )
41
- from sourceSets. main. allSource
42
- }
43
-
44
- repositories {
45
- mavenCentral()
46
- }
47
-
48
- dependencies {
49
- testCompile group : ' junit' , name : ' junit' , version : ' [4.3,5.0]'
50
- testCompile group : ' com.github.tomakehurst' , name : ' wiremock' , version : ' [1.45,2.0]'
51
- compile group : ' commons-lang' , name : ' commons-lang' , version : ' [2.6,3.0]'
52
- compile group : ' org.asynchttpclient' , name : ' async-http-client' , version : ' [2.0,2.99999)'
53
- compile group : ' com.fasterxml.jackson.core' , name : ' jackson-databind' , version : ' [2.3.1,2.99999)'
54
- compile group : ' commons-validator' , name : ' commons-validator' , version : ' [1.4.0,1.99999)'
55
- compile group : ' commons-codec' , name : ' commons-codec' , version : ' [1.9,1.99999]'
56
- compile group : ' org.bitbucket.b_c' , name : ' jose4j' , version : ' [0.7,1.0)'
57
- // TODO: find out how to initialize these dependencies properly, or remove them
58
- // compile group: 'org.slf4j', name: 'slf4j-api', version: '1.7.5'
59
- // compile group: 'org.slf4j', name: 'slf4j-simple', version: '1.7.5'
60
- }
59
+ check. dependsOn jacocoTestReport
61
60
62
61
license {
63
62
header rootProject. file(' codequality/HEADER' )
@@ -69,7 +68,6 @@ artifacts {
69
68
}
70
69
71
70
ext. isReleaseVersion = hasProperty(' isReleaseVersion' ) ? isReleaseVersion : false
72
-
73
71
ext. ossrhUsername = hasProperty(' ossrhUsername' ) ? ossrhUsername : ' dummyuser'
74
72
ext. ossrhPassword = hasProperty(' ossrhPassword' ) ? ossrhPassword : ' dummypass'
75
73
@@ -107,28 +105,34 @@ publishing {
107
105
email = ' aoberoi@gmail.com'
108
106
organization = ' Vonage'
109
107
}
110
- developer{
108
+ developer {
111
109
id = ' slorello89'
112
110
name = ' Steve Lorello'
113
111
email = ' steve.lorello@vonage.com'
114
112
organization = ' Vonage'
115
113
}
114
+ developer {
115
+ id = ' SMadani'
116
+ name = ' Sina Madani'
117
+ email = ' sina.madani@vonage.com'
118
+ organization = ' Vonage'
119
+ }
116
120
}
117
121
scm {
118
122
connection = " scm:git@github.com/opentok/opentok-java-sdk"
119
123
developerConnection = " scm:git@github.com/opentok/opentok-java-sdk"
120
124
url = " http://github.com/opentok/opentok-java-sdk"
121
125
}
122
126
123
- issueManagement{
127
+ issueManagement {
124
128
system = " GitHub"
125
129
url = " https://http://github.com/opentok/opentok-java-sdk"
126
130
}
127
131
}
128
132
}
129
133
}
130
- repositories{
131
- maven{
134
+ repositories {
135
+ maven {
132
136
def releasesRepoUrl = uri(" https://oss.sonatype.org/service/local/staging/deploy/maven2/" )
133
137
def snapshotsRepoUrl = uri(" https://oss.sonatype.org/content/repositories/snapshots/" )
134
138
credentials. username(System . getenv(" OSS_USERNAME" ))
@@ -149,7 +153,6 @@ test {
149
153
maxHeapSize = " 1024m"
150
154
}
151
155
152
- sourceCompatibility = 1.8
153
156
// credit: http://stackoverflow.com/a/22681854/305340
154
157
tasks. withType(JavaCompile ) {
155
158
options. compilerArgs << " -Xlint:deprecation" << " -Xlint:unchecked"
0 commit comments