|
2 | 2 | * Copyright (c) 2014-2017 Afero, Inc. All rights reserved. |
3 | 3 | */ |
4 | 4 |
|
5 | | -apply plugin: 'java' |
| 5 | +plugins { |
| 6 | + id 'java-library' |
| 7 | + id 'maven-publish' |
| 8 | +} |
6 | 9 |
|
7 | 10 | dependencies { |
8 | 11 | implementation fileTree(dir: 'libs', include: ['*.jar']) |
9 | 12 |
|
10 | 13 | implementation project(path: ':afero-sdk-core') |
11 | 14 |
|
12 | 15 | // https://github.com/square/retrofit |
13 | | - implementation 'com.squareup.retrofit2:retrofit:2.3.0' |
14 | | - implementation 'com.squareup.retrofit2:converter-jackson:2.3.0' |
15 | | - implementation 'com.squareup.retrofit2:adapter-rxjava:2.3.0' |
16 | | - implementation 'com.squareup.retrofit2:retrofit-mock:2.3.0' |
| 16 | + implementation 'com.squareup.retrofit2:retrofit:3.0.0' |
| 17 | + implementation 'com.squareup.retrofit2:converter-jackson:3.0.0' |
| 18 | + implementation 'com.squareup.retrofit2:adapter-rxjava:3.0.0' |
| 19 | + implementation 'com.squareup.retrofit2:retrofit-mock:3.0.0' |
17 | 20 |
|
18 | 21 | // https://github.com/square/okhttp |
19 | | - implementation 'com.squareup.okhttp3:okhttp:3.8.0' |
20 | | - implementation 'com.squareup.okhttp3:logging-interceptor:3.8.0' |
| 22 | + implementation 'com.squareup.okhttp3:okhttp:5.3.0' |
| 23 | + implementation 'com.squareup.okhttp3:logging-interceptor:5.3.0' |
21 | 24 |
|
22 | 25 | // https://github.com/FasterXML/jackson |
23 | | - implementation 'com.fasterxml.jackson.core:jackson-databind:2.8.5' |
24 | | - implementation 'com.fasterxml.jackson.core:jackson-core:2.8.5' |
25 | | - implementation 'com.fasterxml.jackson.core:jackson-annotations:2.8.5' |
| 26 | + implementation 'com.fasterxml.jackson.core:jackson-databind:2.20.1' |
| 27 | + implementation 'com.fasterxml.jackson.core:jackson-core:2.20.1' |
| 28 | + implementation 'com.fasterxml.jackson.core:jackson-annotations:2.20' |
26 | 29 |
|
27 | 30 | // https://github.com/ReactiveX/RxJava |
28 | | - implementation 'io.reactivex:rxjava:1.3.0' |
| 31 | + implementation 'io.reactivex:rxjava:1.3.8' |
29 | 32 | } |
30 | 33 |
|
31 | | -sourceCompatibility = JavaVersion.VERSION_1_7 |
32 | | -targetCompatibility = JavaVersion.VERSION_1_7 |
33 | | - |
34 | | -publishing { |
35 | | - publications { |
36 | | - jar(MavenPublication) { |
37 | | - version = rootProject.version |
38 | | - artifactId project.getName() |
39 | | - groupId rootProject.group |
40 | | - |
41 | | - artifact("$buildDir/libs/${project.getName()}.jar") |
42 | | -// artifact packageJavadoc |
43 | | - |
44 | | - pom.withXml { |
45 | | - def dependencies = asNode().appendNode('dependencies') |
46 | | - configurations.getByName("compile").getResolvedConfiguration().getFirstLevelModuleDependencies().each { |
47 | | - // don't include local dependencies |
48 | | - if (it.moduleVersion != 'unspecified') { |
49 | | - def dependency = dependencies.appendNode('dependency') |
50 | | - dependency.appendNode('groupId', it.moduleGroup) |
51 | | - dependency.appendNode('artifactId', it.moduleName) |
52 | | - dependency.appendNode('version', it.moduleVersion) |
53 | | - } |
54 | | - } |
| 34 | +sourceCompatibility = JavaVersion.VERSION_17 |
| 35 | +targetCompatibility = JavaVersion.VERSION_17 |
| 36 | + |
| 37 | +afterEvaluate { |
| 38 | + publishing { |
| 39 | + publications { |
| 40 | + release(MavenPublication) { |
| 41 | + from components.java |
| 42 | + groupId rootProject.group |
| 43 | + version = rootProject.version |
| 44 | + artifactId project.name |
55 | 45 | } |
56 | | - } |
| 46 | + } |
| 47 | + repositories { |
| 48 | + maven { |
| 49 | + url = 'https://afero.jfrog.io/afero/afero-java-sdk' |
| 50 | + credentials { |
| 51 | + username = project.findProperty('aferoArtifactoryUserName') ?: "" |
| 52 | + password = project.findProperty('aferoArtifactoryPassword') ?: "" |
| 53 | + } |
| 54 | + } |
| 55 | + } |
57 | 56 | } |
58 | 57 | } |
59 | | - |
60 | | -javadoc { |
61 | | - options.addStringOption('Xdoclint:none', '-quiet') |
62 | | - options.links("https://square.github.io/okhttp/3.x/okhttp/") |
63 | | - options.links("https://square.github.io/retrofit/2.x/retrofit/") |
64 | | - options.links("http://fasterxml.github.io/jackson-annotations/javadoc/2.8/") |
65 | | - options.links("http://fasterxml.github.io/jackson-core/javadoc/2.8/") |
66 | | - options.links("http://fasterxml.github.io/jackson-databind/javadoc/2.8/") |
67 | | -} |
68 | | - |
69 | | -task packageJavadoc(type: Jar) { |
70 | | - from javadoc |
71 | | - classifier = 'javadoc' |
72 | | -} |
0 commit comments