Skip to content

Commit a8e9b07

Browse files
author
Mihail Slavchev
authored
Merge pull request #616 from NativeScript/slavchev/filter-build
filter *.dex files by build type
2 parents 75e5b43 + 1359f05 commit a8e9b07

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

build-artifacts/project-template-gradle/build.gradle

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -569,8 +569,12 @@ task buildMetadata (type: JavaExec) {
569569
metadataParams.add(androidJar)
570570

571571
def ft = fileTree(dir: "$buildDir/intermediates/transforms/dex", include: "**/*.dex")
572+
def buildDirPattern = File.separator + project.ext.selectedBuildType + File.separator
572573
ft.each { currentDexFile ->
573-
metadataParams.add(currentDexFile.getAbsolutePath())
574+
def dexFilepath = currentDexFile.getAbsolutePath()
575+
if (dexFilepath.contains(buildDirPattern)) {
576+
metadataParams.add(dexFilepath)
577+
}
574578
}
575579

576580
workingDir "build-tools"

0 commit comments

Comments
 (0)