@@ -217,7 +217,7 @@ bintray {
217217 user = System . getenv(' BINTRAY_USER' )
218218 key = System . getenv(' BINTRAY_API_KEY' )
219219
220- publications = [" MyPublication " ]
220+ publications = [" mavenAar " ]
221221
222222 publish = true
223223 pkg {
@@ -244,35 +244,20 @@ bintray {
244244}
245245
246246// Create the publication with the pom configuration:
247- apply plugin : ' maven-publish'
247+ apply plugin : ' digital.wup.android-maven-publish'
248+
248249publishing {
249250 publications {
250- MyPublication (MavenPublication ) {
251+ mavenAar(MavenPublication ) {
252+ from components. android
251253 groupId group
252254 // We have to specify it here because otherwise Bintray's plugin will assume the artifact's name is Parse
253255 artifactId artifact
254256 artifacts = [androidSourcesJar, javadocJarRelease, bundleRelease]
255257 version version
256- pom. withXml {
257- def root = asNode()
258- root. appendNode(' description' , projDescription)
259- root. appendNode(' name' , projName)
260- root. appendNode(' url' , gitLink)
261- root. children(). last() + pomConfig
262-
263- // maven-publish workaround to include dependencies
264- def dependenciesNode = asNode(). appendNode(' dependencies' )
265-
266- // Iterate over the compile dependencies (we don't want the test ones), adding a <dependency> node for each
267- configurations. implementation. allDependencies. each {
268- def dependencyNode = dependenciesNode. appendNode(' dependency' )
269- dependencyNode. appendNode(' groupId' , it. group)
270- dependencyNode. appendNode(' artifactId' , it. name)
271- dependencyNode. appendNode(' version' , it. version)
272- }
273-
274- }
258+
275259 }
260+
276261 }
277262}
278263
@@ -292,7 +277,7 @@ artifactory {
292277 }
293278 defaults {
294279 publishArtifacts = true
295- publications(' MyPublication ' )
280+ publications(' mavenAar ' )
296281 }
297282 }
298283}
0 commit comments