Skip to content

Commit

Permalink
fix bug that task name already exists #48
Browse files Browse the repository at this point in the history
  • Loading branch information
kezong committed Aug 8, 2019
1 parent 4c0cde7 commit 1fa3dc6
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -112,11 +112,14 @@ class VariantProcessor {
archiveLibrary.getRootFolder().deleteDir()
final def zipFolder = archiveLibrary.getRootFolder()
zipFolder.mkdirs()
String taskName = "explode${artifact.name.capitalize()}${mVariant.name.capitalize()}"
def group = artifact.getModuleVersion().id.group.capitalize()
def name = artifact.name.capitalize()
String taskName = "explode${group}${name}${mVariant.name.capitalize()}"
Task explodeTask = mProject.tasks.create(name: taskName, type: Copy) {
from mProject.zipTree(artifact.file.absolutePath)
into zipFolder
}

if (buildDependencies.size() == 0) {
explodeTask.dependsOn(prepareTask)
} else {
Expand Down

0 comments on commit 1fa3dc6

Please sign in to comment.