Skip to content

Commit 3f4e7fc

Browse files
authored
Onboard to the OSS Community Develocity Instance (#55)
1 parent 943daa7 commit 3f4e7fc

4 files changed

Lines changed: 29 additions & 3 deletions

File tree

‎.github/workflows/precommit.yml‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ jobs:
2323
uses: gradle/actions/setup-gradle@v5
2424
with:
2525
gradle-version: ${{ matrix.gradle-version }}
26+
develocity-access-key: ${{ secrets.DEVELOCITY_ACCESS_KEY }}
2627
- name: Build Plugin
2728
run: gradle build
2829
- name: Sample Analysis

‎.github/workflows/publish.yml‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ jobs:
1414
java-version: 17
1515
- name: Setup Gradle
1616
uses: gradle/actions/setup-gradle@v5
17+
with:
18+
develocity-access-key: ${{ secrets.DEVELOCITY_ACCESS_KEY }}
1719
- name: Build Plugin
1820
env:
1921
GRADLE_PUBLISH_KEY: ${{ secrets.GRADLE_PUBLISH_KEY }}

‎README.md‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
# Graph Analytics Plugin
44

5+
[![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)
6+
57
## About This Project
68

79
This [Gradle](https://gradle.org/) plugin was designed to be used in multi-module

‎settings.gradle.kts‎

Lines changed: 24 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,8 @@ pluginManagement {
77
}
88

99
plugins {
10-
id("com.gradle.develocity") version("4.0.2")
10+
id("com.gradle.develocity") version("4.5.0")
11+
id("com.gradle.common-custom-user-data-gradle-plugin") version("2.8.0")
1112
}
1213

1314
dependencyResolutionManagement {
@@ -19,9 +20,29 @@ dependencyResolutionManagement {
1920

2021
rootProject.name = "graph-analytics-plugin"
2122

23+
val isCI = System.getenv("CI") != null
24+
2225
develocity {
26+
server = "https://community.develocity.cloud"
27+
projectId = "ebay"
2328
buildScan {
24-
termsOfUseUrl.set("https://gradle.com/help/legal-terms-of-use")
25-
termsOfUseAgree.set("yes")
29+
uploadInBackground = !isCI
30+
publishing.onlyIf { it.isAuthenticated }
31+
obfuscation {
32+
ipAddresses { addresses -> addresses.map { _ -> "0.0.0.0" } }
33+
}
34+
}
35+
}
36+
37+
buildCache {
38+
local {
39+
isEnabled = true
40+
}
41+
42+
remote(develocity.buildCache) {
43+
isEnabled = true
44+
// Check access key presence to avoid build cache errors on PR builds when access key is not present
45+
val accessKey = System.getenv("DEVELOCITY_ACCESS_KEY")
46+
isPush = isCI && accessKey != null
2647
}
2748
}

0 commit comments

Comments
 (0)