1
1
apply plugin : ' com.android.library'
2
- apply plugin : ' digital.wup.android- maven-publish'
2
+ apply plugin : ' maven-publish'
3
3
apply plugin : ' org.jetbrains.dokka-android'
4
4
5
5
dependencies {
6
- implementation ' androidx.lifecycle:lifecycle-runtime:2.0 .0'
6
+ implementation ' androidx.lifecycle:lifecycle-runtime:2.2 .0'
7
7
8
- compileOnly ' androidx.annotation:annotation:1.0 .0'
8
+ compileOnly ' androidx.annotation:annotation:1.1 .0'
9
9
10
10
api ' com.google.auto.value:auto-value-annotations:1.6.2'
11
11
annotationProcessor ' com.google.auto.value:auto-value:1.6.2'
@@ -35,51 +35,54 @@ android {
35
35
}
36
36
}
37
37
38
- publishing {
39
- publications {
40
- mavenAar( MavenPublication ) {
41
- groupId = ' de.cotech '
42
- artifactId = ' hwsecurity '
43
- version = android . defaultConfig . versionName
38
+ // https://developer.android.com/studio/build/maven-publish-plugin
39
+ afterEvaluate {
40
+ publishing {
41
+ publications {
42
+ release( MavenPublication ) {
43
+ from components . release
44
44
45
- from components. android
45
+ groupId = ' de.cotech'
46
+ artifactId = ' hwsecurity'
47
+ version = android. defaultConfig. versionName
46
48
47
- pom {
48
- url = ' https://hwsecurity.dev'
49
- licenses {
50
- license {
51
- name = ' Commercial'
52
- url = ' https://hwsecurity.dev/sales/'
53
- distribution = ' repo'
49
+ pom {
50
+ url = ' https://hwsecurity.dev'
51
+ licenses {
52
+ license {
53
+ name = ' Commercial'
54
+ url = ' https://hwsecurity.dev/sales/'
55
+ distribution = ' repo'
56
+ }
57
+ license {
58
+ name = ' GNU General Public License, version 3'
59
+ url = ' https://www.gnu.org/licenses/gpl-3.0.txt'
60
+ }
54
61
}
55
- license {
56
- name = ' GNU General Public License, version 3 '
57
- url = ' https://www.gnu.org/licenses/gpl-3.0.txt '
62
+ organization {
63
+ name = ' Confidential Technologies GmbH '
64
+ url = ' https://www.cotech.de '
58
65
}
59
66
}
60
- organization {
61
- name = ' Confidential Technologies GmbH'
62
- url = ' https://www.cotech.de'
63
- }
64
67
}
65
68
}
66
- }
67
- /*
68
- * To upload release, create file gradle.properties in ~/.gradle/ with this content:
69
- *
70
- * cotechMavenName=xxx
71
- * cotechMavenPassword=xxx
72
- */
73
- if (project. hasProperty(' cotechMavenName' ) && project. hasProperty(' cotechMavenPassword' )) {
74
- println " Found cotechMavenName, cotechMavenPassword in gradle.properties!"
69
+ /*
70
+ * To upload release, create file gradle.properties in ~/.gradle/ with this content:
71
+ *
72
+ * cotechMavenName=xxx
73
+ * cotechMavenPassword=xxx
74
+ */
75
+ if (project. hasProperty(' cotechMavenName' ) && project. hasProperty(' cotechMavenPassword' )) {
76
+ println " Found cotechMavenName, cotechMavenPassword in gradle.properties!"
75
77
76
- repositories {
77
- maven {
78
- credentials {
79
- username cotechMavenName
80
- password cotechMavenPassword
78
+ repositories {
79
+ maven {
80
+ credentials {
81
+ username cotechMavenName
82
+ password cotechMavenPassword
83
+ }
84
+ url = " https://maven.cotech.de"
81
85
}
82
- url = " https://maven.cotech.de"
83
86
}
84
87
}
85
88
}
@@ -90,8 +93,9 @@ dokka {
90
93
dokkaFatJar = files(' libs/dokka-hugo-fatjar-0.9.17.jar' )
91
94
// does not work correctly with Maven:
92
95
// dokkaFatJar = 'de.cotech:dokka-hugo-fatjar:0.9.17'
96
+ moduleName = ' hwsecurity'
93
97
outputFormat = " hugo"
94
- outputDirectory = " $b uildDir /dokka /reference"
98
+ outputDirectory = " $p rojectDir /../../hwsecurity.dev/content /reference"
95
99
sourceDirs = files(' src/main/java' )
96
100
97
101
packageOptions {
0 commit comments