-
Notifications
You must be signed in to change notification settings - Fork 33
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Configure Develocity Gradle plugin in Convention Gradle plugin
* Update Convention Develocity Gradle plugin to use Develocity Gradle plugin * Add verification workflow for Convention Develocity Gradle plugin * Fail workflow if no Build Scan published * Change example folder names * Add build for Gradle 2 through 4 * Test more Gradle versions * Run wrapper command twice * Align Gradle 5 wrapper with tested version
- Loading branch information
1 parent
ab67be2
commit 927a74c
Showing
29 changed files
with
119 additions
and
67 deletions.
There are no files selected for viewing
87 changes: 87 additions & 0 deletions
87
.github/workflows/convention-develocity-gradle-plugin-verification.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,87 @@ | ||
name: Verify Convention Develocity Gradle Plugin | ||
|
||
on: | ||
push: | ||
branches: [ main ] | ||
pull_request: | ||
branches: [ main ] | ||
workflow_dispatch: | ||
|
||
jobs: | ||
build: | ||
name: Build Convention Develocity Gradle Plugin | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Set up JDK 8 | ||
uses: actions/setup-java@v4 | ||
with: | ||
java-version: '8' | ||
distribution: 'temurin' | ||
- name: Set up Gradle | ||
uses: gradle/actions/setup-gradle@v3 | ||
- name: Build with Gradle - Gradle 2 through 4 | ||
working-directory: convention-develocity-gradle-plugin/plugins/gradle-2-through-4 | ||
run: ./gradlew build | ||
- name: Build with Gradle - Gradle 5 or newer | ||
working-directory: convention-develocity-gradle-plugin/plugins/gradle-5-or-newer | ||
run: ./gradlew build publishToMavenLocal | ||
- name: Upload plugin | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: convention-develocity-gradle-plugin | ||
path: ~/.m2/repository/com/myorg | ||
|
||
verification: | ||
name: Verify Example Build for Gradle ${{ matrix.versions.version }} | ||
needs: [build] | ||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
# Gradle 3 and earlier is not tested because it does not apply CCUD and overriding the server URL is not possible. | ||
# Gradle 4 is not tested because it does not support publishing to authenticated servers. | ||
versions: | ||
- sample: '5' | ||
version: '5.0' | ||
- sample: '6_and_later' | ||
version: '6.0.1' | ||
- sample: '6_and_later' | ||
version: '7.0.2' | ||
- sample: '6_and_later' | ||
version: '8.0.2' | ||
- sample: '6_and_later' | ||
version: '(Current)' | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Set up JDK 8 | ||
uses: actions/setup-java@v4 | ||
with: | ||
java-version: '8' | ||
distribution: 'temurin' | ||
- name: Set up Gradle | ||
uses: gradle/actions/setup-gradle@v3 | ||
- name: Download plugin | ||
uses: actions/download-artifact@v4 | ||
with: | ||
name: convention-develocity-gradle-plugin | ||
path: ~/.m2/repository/com/myorg | ||
- name: Set Gradle version | ||
if: ${{ matrix.versions.version != '(Current)' }} | ||
working-directory: convention-develocity-gradle-plugin/examples/gradle_${{ matrix.versions.sample }} | ||
run: | | ||
./gradlew wrapper --gradle-version=${{ matrix.versions.version }} | ||
./gradlew wrapper --gradle-version=${{ matrix.versions.version }} | ||
env: | ||
DEVELOCITY_ACCESS_KEY: ${{ secrets.GE_SOLUTIONS_ACCESS_TOKEN }} | ||
- name: Verify example build | ||
id: build | ||
working-directory: convention-develocity-gradle-plugin/examples/gradle_${{ matrix.versions.sample }} | ||
run: ./gradlew build -Ddevelocity.url=https://ge.solutions-team.gradle.com | ||
env: | ||
DEVELOCITY_ACCESS_KEY: ${{ secrets.GE_SOLUTIONS_ACCESS_TOKEN }} | ||
- name: Verify Build Scan published | ||
if: ${{ !steps.build.outputs.build-scan-url }} | ||
run: echo "::error ::No Build Scan published"; exit 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Binary file removed
BIN
-54.3 KB
convention-develocity-gradle-plugin/examples/gradle_5.1.1/gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
File renamed without changes.
Binary file added
BIN
+54.4 KB
convention-develocity-gradle-plugin/examples/gradle_5/gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
2 changes: 1 addition & 1 deletion
2
.../gradle/wrapper/gradle-wrapper.properties → .../gradle/wrapper/gradle-wrapper.properties
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
distributionBase=GRADLE_USER_HOME | ||
distributionPath=wrapper/dists | ||
distributionUrl=https\://services.gradle.org/distributions/gradle-5.1.1-bin.zip | ||
distributionUrl=https\://services.gradle.org/distributions/gradle-5.0-bin.zip | ||
zipStoreBase=GRADLE_USER_HOME | ||
zipStorePath=wrapper/dists |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters