|
1 | | -buildscript { |
2 | | - ext.kotlinVersion = '1.4.10' |
3 | | - ext.kotlin_ktx_version = '1.2.0' |
4 | | - |
5 | | - repositories { |
6 | | - google() |
7 | | - jcenter() |
8 | | - maven { url 'https://a8c-libs.s3.amazonaws.com/android' } |
9 | | - } |
10 | | - dependencies { |
11 | | - classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlinVersion" |
12 | | - classpath 'com.android.tools.build:gradle:4.0.2' |
13 | | - classpath 'com.automattic.android:publish-to-s3:0.4.2' |
14 | | - } |
| 1 | +plugins { |
| 2 | + id "com.android.library" |
| 3 | + id "org.jetbrains.kotlin.android" |
| 4 | + id "com.automattic.android.publish-to-s3" |
15 | 5 | } |
16 | 6 |
|
17 | | -apply plugin: 'com.android.library' |
18 | | -apply plugin: 'kotlin-android' |
19 | | -apply plugin: 'kotlin-android-extensions' |
20 | | -apply plugin: 'com.automattic.android.publish-library-to-s3' |
| 7 | +ext.kotlin_ktx_version = '1.5.0' |
21 | 8 |
|
22 | 9 | repositories { |
23 | 10 | google() |
24 | | - jcenter() |
| 11 | + mavenCentral() |
| 12 | + maven { url 'https://a8c-libs.s3.amazonaws.com/android' } |
25 | 13 | } |
26 | 14 |
|
27 | 15 | dependencies { |
28 | 16 | implementation 'org.apache.commons:commons-text:1.1' |
29 | | - implementation 'com.android.volley:volley:1.1.1' |
| 17 | + implementation 'com.android.volley:volley:1.2.0' |
30 | 18 | implementation 'com.google.android.material:material:1.2.1' |
31 | 19 | implementation "androidx.swiperefreshlayout:swiperefreshlayout:1.1.0" |
32 | 20 | implementation 'androidx.recyclerview:recyclerview:1.0.0' |
33 | 21 | implementation 'org.greenrobot:eventbus:3.0.0' |
34 | 22 |
|
35 | 23 | implementation "androidx.core:core-ktx:$kotlin_ktx_version" |
36 | | - implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlinVersion" |
| 24 | + implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$gradle.ext.kotlinVersion" |
37 | 25 |
|
38 | 26 | testImplementation 'junit:junit:4.12' |
39 | 27 | testImplementation 'org.assertj:assertj-core:3.11.1' |
40 | 28 | testImplementation "org.robolectric:robolectric:4.4" |
41 | 29 | testImplementation 'androidx.test:core:1.0.0' |
42 | 30 |
|
43 | | - lintChecks 'org.wordpress:lint:1.0.1' |
| 31 | + lintChecks 'org.wordpress:lint:1.1.0' |
44 | 32 | androidTestImplementation 'androidx.test:runner:1.1.0' |
45 | 33 | androidTestImplementation 'androidx.test:rules:1.1.0' |
46 | 34 | androidTestImplementation 'androidx.test.ext:junit:1.1.0' |
@@ -70,26 +58,22 @@ android { |
70 | 58 | } |
71 | 59 | } |
72 | 60 |
|
73 | | -android.libraryVariants.all { variant -> |
74 | | - task("generate${variant.name}Javadoc", type: Javadoc) { |
75 | | - description "Generates Javadoc for $variant.name." |
76 | | - source = variant.javaCompile.source |
| 61 | +project.afterEvaluate { |
| 62 | + publishing { |
| 63 | + publications { |
| 64 | + UtilsPublication(MavenPublication) { |
| 65 | + from components.release |
77 | 66 |
|
78 | | - options { |
79 | | - links "http://docs.oracle.com/javase/7/docs/api/" |
| 67 | + groupId "org.wordpress" |
| 68 | + artifactId "utils" |
| 69 | + // version is set by 'publish-to-s3' plugin |
| 70 | + } |
80 | 71 | } |
81 | | - exclude '**/R.java' |
82 | | - doFirst { |
83 | | - classpath = |
84 | | - files(variant.javaCompile.classpath.files, |
85 | | - project.android.getBootClasspath()) |
86 | | - } |
87 | | - } |
| 72 | + } |
88 | 73 | } |
89 | 74 |
|
90 | | -s3PublishLibrary { |
91 | | - groupId "org.wordpress" |
92 | | - artifactId "utils" |
93 | | - from "release" |
| 75 | +publishToS3Plugin { |
| 76 | + mavenPublishGroupId "org.wordpress" |
| 77 | + mavenPublishArtifactId "utils" |
94 | 78 | } |
95 | 79 |
|
0 commit comments