Updated on 2026-08-14

This commit is contained in:
Tangem 2023-06-06 14:26:31 +03:00
parent 8262c72f40
commit 99b4c180cc
4 changed files with 36 additions and 11 deletions

View file

@ -73,4 +73,29 @@ val assembleQA by tasks.registering {
dependsOn(assembleInternalQA)
dependsOn(assembleExternalQA)
}
val generateComposeMetrics by tasks.registering {
group = "other"
description = "Build external APK and generates compose metrics to 'build/compose-metrics' directory"
subprojects {
tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile> {
compilerOptions {
val outputDirectory = "${project.buildDir.absolutePath}/compose_metrics"
// Metrics
freeCompilerArgs.addAll(
"-P",
"plugin:androidx.compose.compiler.plugins.kotlin:metricsDestination=$outputDirectory",
)
// Reports
freeCompilerArgs.addAll(
"-P",
"plugin:androidx.compose.compiler.plugins.kotlin:reportsDestination=$outputDirectory",
)
}
}
}
finalizedBy(assembleExternalQA)
}