diff --git a/.buildkite/schedules/dependency-analysis.yml b/.buildkite/schedules/dependency-analysis.yml new file mode 100644 index 000000000000..fb6cd3b469f7 --- /dev/null +++ b/.buildkite/schedules/dependency-analysis.yml @@ -0,0 +1,23 @@ +# Nodes with values to reuse in the pipeline. +common_params: + # Common plugin settings to use with the `plugins` key. + - &ci_toolkit + automattic/a8c-ci-toolkit#3.4.2 + +agents: + queue: "android" + +steps: + - label: "dependency analysis" + # The meta-data added is used by Apps Metrics Prometheus collector to find the build. + command: | + buildkite-agent meta-data set "scheduled-build" "dependency-analysis" + echo "--- 📊 Analyzing" + cp gradle.properties-example gradle.properties + ./gradlew buildHealth + plugins: [*ci_toolkit] + artifact_paths: + - "build/reports/dependency-analysis/build-health-report.*" + notify: + - slack: "#android-core-notifs" + if: build.state == "failed" diff --git a/.configure b/.configure index d6e9f159bcec..9abd2a6ba5c6 100644 --- a/.configure +++ b/.configure @@ -1,7 +1,7 @@ { "project_name": "WordPress-Android", "branch": "trunk", - "pinned_hash": "715a5a119a334ec1ef16b5a6bd77c52094144813", + "pinned_hash": "4b536af182cc61c263b07262e41c141f06fd5de6", "files_to_copy": [ { "file": "android/WPAndroid/gradle.properties", diff --git a/.configure-files/gradle.properties.enc b/.configure-files/gradle.properties.enc index c2c83c9d1071..cfe19b47de6b 100644 Binary files a/.configure-files/gradle.properties.enc and b/.configure-files/gradle.properties.enc differ diff --git a/build.gradle b/build.gradle index 35cbeef403dd..4e6632668e9c 100644 --- a/build.gradle +++ b/build.gradle @@ -5,6 +5,7 @@ plugins { id "io.gitlab.arturbosch.detekt" id 'com.automattic.android.measure-builds' id "org.jetbrains.kotlinx.kover" + id "com.autonomousapps.dependency-analysis" id "androidx.navigation.safeargs.kotlin" apply false id "com.android.library" apply false id 'com.google.gms.google-services' apply false diff --git a/gradle.properties-example b/gradle.properties-example index 8e52efd546b9..4fef2c46ec7b 100644 --- a/gradle.properties-example +++ b/gradle.properties-example @@ -48,3 +48,6 @@ wp.e2e.signup_email=e2eflowsignuptestingmobile@example.com wp.e2e.signup_username=e2eflowsignuptestingmobile wp.e2e.signup_display_name=e2eflowsignuptestingmobile wp.e2e.signup_password=mocked_password + +# Dependency Analysis Plugin +dependency.analysis.android.ignored.variants=release,wordpressVanillaDebug,wordpressVanillaRelease,wordpressWasabiDebug,wordpressWasabiRelease,wordpressJalapenoRelease,jetpackVanillaDebug,jetpackVanillaRelease,jetpackWasabiDebug,jetpackWasabiRelease,jetpackJalapenoRelease diff --git a/settings.gradle b/settings.gradle index 0d1018fd702f..ce16fc371913 100644 --- a/settings.gradle +++ b/settings.gradle @@ -10,6 +10,7 @@ pluginManagement { gradle.ext.violationCommentsVersion = '1.70.0' gradle.ext.measureBuildsVersion = '2.1.2' gradle.ext.koverVersion = '0.7.5' + gradle.ext.dependencyAnalysisVersion = '1.28.0' plugins { id "org.jetbrains.kotlin.android" version gradle.ext.kotlinVersion @@ -28,6 +29,7 @@ pluginManagement { id "org.jetbrains.kotlinx.kover" version gradle.ext.koverVersion id "com.google.dagger.hilt.android" version gradle.ext.daggerVersion id "com.google.devtools.ksp" version gradle.ext.kspVersion + id "com.autonomousapps.dependency-analysis" version gradle.ext.dependencyAnalysisVersion } repositories { maven {