Skip to content

Commit

Permalink
Merge pull request #1318 from gradle/erichaagdev/workflow-improvements
Browse files Browse the repository at this point in the history
Workflows are improved
  • Loading branch information
erichaagdev authored Aug 12, 2024
2 parents 09782f3 + 35a2646 commit c07871d
Show file tree
Hide file tree
Showing 6 changed files with 23 additions and 17 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ name: Verify Convention Develocity Gradle Plugin
on:
push:
branches: [ main ]
paths: [ 'convention-develocity-gradle-plugin/**' ]
paths: [ 'convention-develocity-gradle-plugin/**', '.github/workflows/**' ]
pull_request:
branches: [ main ]
paths: [ 'convention-develocity-gradle-plugin/**' ]
paths: [ 'convention-develocity-gradle-plugin/**', '.github/workflows/**' ]
workflow_dispatch:

jobs:
Expand Down Expand Up @@ -80,13 +80,13 @@ jobs:
./gradlew wrapper --gradle-version=${{ matrix.versions.version }} --no-scan
./gradlew wrapper --gradle-version=${{ matrix.versions.version }} --no-scan
env:
DEVELOCITY_ACCESS_KEY: ${{ secrets.GE_SOLUTIONS_ACCESS_TOKEN }}
DEVELOCITY_ACCESS_KEY: ${{ secrets.DV_SOLUTIONS_ACCESS_KEY }}
- 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 }}
DEVELOCITY_ACCESS_KEY: ${{ secrets.DV_SOLUTIONS_ACCESS_KEY }}
- name: Verify Build Scan published
if: ${{ !steps.build.outputs.build-scan-url }}
run: echo "::error ::No Build Scan published"; exit 1
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ name: Verify Convention Develocity Maven Extension
on:
push:
branches: [ main ]
paths: [ 'convention-develocity-maven-extension/**' ]
paths: [ 'convention-develocity-maven-extension/**', '.github/workflows/**' ]
pull_request:
branches: [ main ]
paths: [ 'convention-develocity-maven-extension/**' ]
paths: [ 'convention-develocity-maven-extension/**', '.github/workflows/**' ]
workflow_dispatch:

jobs:
Expand Down Expand Up @@ -54,6 +54,8 @@ jobs:
java-version: '8'
distribution: 'temurin'
cache: maven
- name: Set up Maven
uses: gradle/develocity-actions/[email protected]
- name: Download extension
uses: actions/download-artifact@v4
with:
Expand All @@ -62,11 +64,15 @@ jobs:
- name: Set Maven version
if: ${{ matrix.versions.version != '(Current)' }}
working-directory: convention-develocity-maven-extension/examples/maven_${{ matrix.versions.sample }}
run: ./mvnw wrapper:wrapper -Dmaven=${{ matrix.versions.version }} -Ddevelocity.url=https://ge.solutions-team.gradle.com
run: ./mvnw wrapper:wrapper -Dmaven=${{ matrix.versions.version }} -Ddevelocity.scan.disabled
env:
DEVELOCITY_ACCESS_KEY: ${{ secrets.GE_SOLUTIONS_ACCESS_TOKEN }}
DEVELOCITY_ACCESS_KEY: ${{ secrets.DV_SOLUTIONS_ACCESS_KEY }}
- name: Verify example build
id: build
working-directory: convention-develocity-maven-extension/examples/maven_${{ matrix.versions.sample }}
run: ./mvnw clean verify -Ddevelocity.url=https://ge.solutions-team.gradle.com
env:
DEVELOCITY_ACCESS_KEY: ${{ secrets.GE_SOLUTIONS_ACCESS_TOKEN }}
DEVELOCITY_ACCESS_KEY: ${{ secrets.DV_SOLUTIONS_ACCESS_KEY }}
- name: Verify Build Scan published
if: ${{ !steps.build.outputs.build-scan-url }}
run: echo "::error ::No Build Scan published"; exit 1
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ name: Verify Gradle Data Capturing Samples
on:
push:
branches: [ main ]
paths: [ 'build-data-capturing-gradle-samples/**' ]
paths: [ 'build-data-capturing-gradle-samples/**', '.github/workflows/**' ]
pull_request:
branches: [ main ]
paths: [ 'build-data-capturing-gradle-samples/**' ]
paths: [ 'build-data-capturing-gradle-samples/**', '.github/workflows/**' ]
workflow_dispatch:

jobs:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ name: Verify Maven Build Caching Samples
on:
push:
branches: [ main ]
paths: [ 'build-caching-maven-samples/**' ]
paths: [ 'build-caching-maven-samples/**', '.github/workflows/**' ]
pull_request:
branches: [ main ]
paths: [ 'build-caching-maven-samples/**' ]
paths: [ 'build-caching-maven-samples/**', '.github/workflows/**' ]
workflow_dispatch:

jobs:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ name: Verify Maven Data Capturing Samples
on:
push:
branches: [ main ]
paths: [ 'build-data-capturing-maven-samples/**' ]
paths: [ 'build-data-capturing-maven-samples/**', '.github/workflows/**' ]
pull_request:
branches: [ main ]
paths: [ 'build-data-capturing-maven-samples/**' ]
paths: [ 'build-data-capturing-maven-samples/**', '.github/workflows/**' ]
workflow_dispatch:

jobs:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/quarkus-build-caching-extension.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ on:
- cron: "0 9 * * 0"
push:
branches: [ main ]
paths: [ 'quarkus-build-caching-extension/**' ]
paths: [ 'quarkus-build-caching-extension/**', '.github/workflows/**' ]
pull_request:
branches: [ main ]
paths: [ 'quarkus-build-caching-extension/**' ]
paths: [ 'quarkus-build-caching-extension/**', '.github/workflows/**' ]
workflow_dispatch:

jobs:
Expand Down

0 comments on commit c07871d

Please sign in to comment.