-
Notifications
You must be signed in to change notification settings - Fork 9
/
build.gradle
124 lines (105 loc) · 3.39 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
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
buildscript {
repositories {
jcenter()
mavenCentral()
}
}
plugins {
id 'java-library'
//Remove 'com.jfrog.artifactory' plugin if you are not using Artifactory
id 'com.jfrog.artifactory' version '4.10.0'
id 'maven-publish'
}
allprojects {
repositories {
jcenter()
mavenCentral()
//Remove maven{} block if you are not using Artifactory, otherwise define your own values in the gradle.properties file
maven {
credentials{
username artifactory_username
password artifactory_password
}
url artifactory_path_android_libraries
}
}
}
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation 'one.block:eosiojava:1.0.0'
implementation 'org.jetbrains:annotations:17.0.0'
implementation (group: 'com.googlecode.json-simple', name: 'json-simple', version: '1.1.1') {
exclude group: 'org.hamcrest', module: 'hamcrest-core'
exclude group: 'junit', module: 'junit'
}
api 'com.squareup.retrofit2:retrofit:2.5.0'
api 'com.squareup.retrofit2:converter-gson:2.5.0'
api 'com.squareup.okhttp3:logging-interceptor:3.12.1'
testCompile group: 'junit', name: 'junit', version: '4.12'
testImplementation 'junit:junit:4.12'
testImplementation 'org.mockito:mockito-core:3.0.0'
testImplementation 'org.powermock:powermock-module-junit4:2.0.2'
testImplementation 'org.powermock:powermock-api-mockito2:2.0.2'
testImplementation 'com.squareup.retrofit2:retrofit:2.5.0'
testImplementation 'com.squareup.retrofit2:converter-gson:2.5.0'
testImplementation 'com.squareup.okhttp3:logging-interceptor:3.12.1'
testImplementation 'com.squareup.okhttp3:mockwebserver:3.12.1'
// These are for LiveServerUnitTest.
testImplementation 'one.block:eosiojavasoftkeysignatureprovider:1.0.0'
testImplementation 'one.block:eosio-java-abieos-serialization-provider:1.0.0'
}
test {
testLogging {
events "passed", "skipped", "failed"
}
}
def libraryGroupId = 'one.block'
def libraryArtifactId = 'eosio-java-rpc-provider'
def libraryVersion = '1.0.0'
task sourcesJar(type: Jar, dependsOn: classes){
classifier = 'sources'
from sourceSets.main.allSource
}
javadoc.failOnError = false
task javadocJar(type: Jar, dependsOn: javadoc){
classifier = 'javadoc'
from javadoc.destinationDir
}
artifacts {
archives sourcesJar
archives javadocJar
}
publishing {
publications {
jar(MavenPublication) {
from components.java
artifact sourcesJar {
classifier "sources"
}
artifact javadocJar {
classifier "javadoc"
}
groupId libraryGroupId
version libraryVersion
artifactId libraryArtifactId
artifact("$buildDir/libs/${artifactId}.jar")
}
}
}
//Remove artifactory{} block if you are not using Artifactory
artifactory {
contextUrl = artifactory_contextURL
publish {
repository {
repoKey = artifactory_repo
username = artifactory_username
password = artifactory_password
}
defaults {
publications('jar')
publishArtifacts = true
properties = ['qa.level': 'basic', 'dev.team': 'core']
publishPom = true
}
}
}