Skip to content

Commit

Permalink
Fix task dependencies for release build
Browse files Browse the repository at this point in the history
  • Loading branch information
Goooler committed Dec 5, 2023
1 parent 7c0f485 commit 49b5567
Showing 1 changed file with 9 additions and 5 deletions.
14 changes: 9 additions & 5 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
import com.android.build.gradle.internal.api.ApkVariantOutputImpl
import com.android.build.gradle.internal.lint.AndroidLintAnalysisTask
import com.android.build.gradle.internal.lint.LintModelWriterTask
import com.android.build.gradle.tasks.MergeSourceSetFolders
import java.io.FileInputStream
import java.util.Locale
import java.util.Properties
Expand Down Expand Up @@ -104,11 +107,12 @@ android {
from(reporting.file("licensee/android$capitalizedName/artifacts.json"))
into(layout.buildDirectory.dir("generated/dependencyAssets/"))
}
tasks.named("merge${capitalizedName}Assets").configure {
dependsOn(copyArtifactList)
}
if (buildType.name == "release") {
tasks.named("lintVitalAnalyze$capitalizedName").configure {
listOf(
AndroidLintAnalysisTask::class,
LintModelWriterTask::class,
MergeSourceSetFolders::class,
).forEach {
tasks.withType(it).configureEach {
dependsOn(copyArtifactList)
}
}
Expand Down

0 comments on commit 49b5567

Please sign in to comment.