From 34ddfbe1cddacf355677453000f2227cc5213372 Mon Sep 17 00:00:00 2001 From: Inaki Villar Date: Tue, 11 Aug 2026 16:10:08 -0700 Subject: [PATCH] Onboard to the OSS Community Develocity Instance --- .github/workflows/precommit.yml | 1 + .github/workflows/publish.yml | 2 ++ README.md | 2 ++ settings.gradle.kts | 27 ++++++++++++++++++++++++--- 4 files changed, 29 insertions(+), 3 deletions(-) diff --git a/.github/workflows/precommit.yml b/.github/workflows/precommit.yml index cbac95e..17bf8a9 100644 --- a/.github/workflows/precommit.yml +++ b/.github/workflows/precommit.yml @@ -23,6 +23,7 @@ jobs: uses: gradle/actions/setup-gradle@v5 with: gradle-version: ${{ matrix.gradle-version }} + develocity-access-key: ${{ secrets.DEVELOCITY_ACCESS_KEY }} - name: Build Plugin run: gradle build - name: Sample Analysis diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 642f897..55e4103 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -14,6 +14,8 @@ jobs: java-version: 17 - name: Setup Gradle uses: gradle/actions/setup-gradle@v5 + with: + develocity-access-key: ${{ secrets.DEVELOCITY_ACCESS_KEY }} - name: Build Plugin env: GRADLE_PUBLISH_KEY: ${{ secrets.GRADLE_PUBLISH_KEY }} diff --git a/README.md b/README.md index 6a0ab8a..895ee76 100644 --- a/README.md +++ b/README.md @@ -2,6 +2,8 @@ # Graph Analytics Plugin +[![Revved up by Develocity](https://img.shields.io/badge/Revved%20up%20by-Develocity-06A0CE?logo=Gradle&labelColor=02303A)](https://community.develocity.cloud/scans?search.rootProjectNames=graph-analytics-plugin) + ## About This Project This [Gradle](https://gradle.org/) plugin was designed to be used in multi-module diff --git a/settings.gradle.kts b/settings.gradle.kts index 69f47f4..3327ac6 100644 --- a/settings.gradle.kts +++ b/settings.gradle.kts @@ -7,7 +7,8 @@ pluginManagement { } plugins { - id("com.gradle.develocity") version("4.0.2") + id("com.gradle.develocity") version("4.5.0") + id("com.gradle.common-custom-user-data-gradle-plugin") version("2.8.0") } dependencyResolutionManagement { @@ -19,9 +20,29 @@ dependencyResolutionManagement { rootProject.name = "graph-analytics-plugin" +val isCI = System.getenv("CI") != null + develocity { + server = "https://community.develocity.cloud" + projectId = "ebay" buildScan { - termsOfUseUrl.set("https://gradle.com/help/legal-terms-of-use") - termsOfUseAgree.set("yes") + uploadInBackground = !isCI + publishing.onlyIf { it.isAuthenticated } + obfuscation { + ipAddresses { addresses -> addresses.map { _ -> "0.0.0.0" } } + } + } +} + +buildCache { + local { + isEnabled = true + } + + remote(develocity.buildCache) { + isEnabled = true + // Check access key presence to avoid build cache errors on PR builds when access key is not present + val accessKey = System.getenv("DEVELOCITY_ACCESS_KEY") + isPush = isCI && accessKey != null } }