diff options
author | Aurimas Liutikas <aurimas@google.com> | 2017-04-28 11:38:10 -0700 |
---|---|---|
committer | Aurimas Liutikas <aurimas@google.com> | 2017-04-28 11:38:10 -0700 |
commit | fd97bb8f04182220658b39cce4601aa9bada0b6f (patch) | |
tree | 380cc9ed71a59c77a00e21b0863065daa4505f0e | |
parent | 74fde7f748f1847bcbe724d73b6184de1dcba95c (diff) | |
download | multidex-fd97bb8f04182220658b39cce4601aa9bada0b6f.tar.gz |
Update multidex dist task to build and zip maven repository instead of just aar.
Bug: 36122649
Test: ./gradlew clean dist
Change-Id: Ia7ace388ba72abff4a167552628b892cae024f7c
-rw-r--r-- | build.gradle | 24 |
1 files changed, 11 insertions, 13 deletions
diff --git a/build.gradle b/build.gradle index 3a5ed75..10fac34 100644 --- a/build.gradle +++ b/build.gradle @@ -66,9 +66,18 @@ ext.supportRepoOut = new File(buildDir, 'support_repo') // upload anchor for subprojects to upload their artifacts // to the local repo. -task(dist) { +task dist(type: Zip) { group = BasePlugin.BUILD_GROUP description 'Builds distribution artifacts.' + + from project.ext.supportRepoOut + into 'm2repository' + destinationDir project.ext.distDir + baseName = String.format("top-of-tree-m2repository-%s", project.multidexVersion) + + doLast { + logger.warn "Compressed maven artifacts to ${archivePath}" + } } subprojects { @@ -89,18 +98,7 @@ subprojects { } } - task createArtifactZip(type: Zip, dependsOn: release) { - from release.artifacts - into archivesBaseName - destinationDir project.parent.distDir - baseName = archivesBaseName - - doLast { - logger.warn "Compressed maven artifacts to ${archivePath}" - } - } - - dist.dependsOn createArtifactZip + dist.dependsOn release project.plugins.whenPluginAdded { plugin -> if ("com.android.build.gradle.LibraryPlugin".equals(plugin.class.name)) { |