Bump the npm-dependencies group with 4 updates #606
Workflow file for this run
This file contains hidden or 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
| name: Build | |
| on: | |
| pull_request: | |
| push: | |
| branches: | |
| - main | |
| - 'releases/*' | |
| permissions: | |
| contents: read | |
| env: | |
| DV_URL: "https://ge.solutions-team.gradle.com" | |
| DV_FAKE_ACCESS_KEY: "ge.solutions-team.gradle.com=foo" | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v6 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v6 | |
| with: | |
| node-version: 24 | |
| cache: npm | |
| - name: Set up JDK 8 | |
| uses: actions/setup-java@v5 | |
| with: | |
| java-version: 8 | |
| distribution: "zulu" | |
| - name: Setup Develocity for npm | |
| uses: ./setup-npm | |
| with: | |
| develocity-url: ${{ env.DV_URL }} | |
| develocity-access-key: ${{ secrets.DV_SOLUTIONS_ACCESS_KEY }} | |
| develocity-injection-enabled: true | |
| - name: Install Dependencies | |
| run: npm ci | |
| - name: Build | |
| run: npm run all | |
| test-capture: | |
| runs-on: ubuntu-latest | |
| if: "github.event_name == 'pull_request'" | |
| needs: build | |
| permissions: | |
| pull-requests: write | |
| steps: | |
| - name: Find PR Comment with publication summary | |
| uses: peter-evans/find-comment@v4 | |
| id: fc | |
| with: | |
| issue-number: ${{ github.event.number }} | |
| body-includes: '###### Generated by gradle/develocity-actions' | |
| - name: Delete PR Comment with publication summary | |
| env: | |
| GH_TOKEN: ${{ github.token }} | |
| run: | | |
| if [[ ! -z "${{ steps.fc.outputs.comment-id }}" ]]; then | |
| echo "Removing PR Comment with publication summary" | |
| gh api --method DELETE "repos/${GITHUB_REPOSITORY}/issues/comments/${{ steps.fc.outputs.comment-id }}" | |
| fi | |
| - name: Checkout | |
| uses: actions/checkout@v6 | |
| - name: Checkout Maven sample project | |
| uses: actions/checkout@v6 | |
| with: | |
| repository: 'gradle/develocity-build-config-samples' | |
| path: 'sample' | |
| ref: 'main' | |
| - name: Set up JDK 17 | |
| uses: actions/setup-java@v5 | |
| with: | |
| java-version: '17' | |
| distribution: 'temurin' | |
| - name: Setup Build Scan dump capture | |
| uses: ./setup-maven | |
| - name: Run Maven Build 1 | |
| working-directory: ./sample/common-develocity-maven-configuration | |
| run: mvn clean -B -X -Ddevelocity.url=${{ env.DV_URL }} | |
| - name: Run Maven Build 2 | |
| working-directory: ./sample/common-develocity-maven-configuration | |
| run: mvn initialize -B -X -Ddevelocity.url=${{ env.DV_URL }} | |
| test-publish: | |
| runs-on: ubuntu-latest | |
| if: "github.event_name == 'pull_request'" | |
| needs: test-capture | |
| permissions: | |
| actions: write | |
| pull-requests: write | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v6 | |
| - name: Setup Build Scan link capture | |
| uses: ./setup-maven | |
| - name: Publish Build Scans | |
| uses: ./maven-publish-build-scan | |
| with: | |
| develocity-url: ${{ env.DV_URL }} | |
| develocity-access-key: ${{ env.DV_FAKE_ACCESS_KEY }} | |
| assert-test: | |
| runs-on: ubuntu-latest | |
| if: "github.event_name == 'pull_request'" | |
| needs: test-publish | |
| steps: | |
| - name: Find PR Comment with publication summary | |
| uses: peter-evans/find-comment@v4 | |
| id: fc | |
| with: | |
| issue-number: ${{ github.event.number }} | |
| body-includes: '###### Generated by gradle/develocity-actions' | |
| - name: Assert PR Comment with publication summary is present | |
| env: | |
| GH_TOKEN: ${{ github.token }} | |
| run: | | |
| if [[ -z "${{ steps.fc.outputs.comment-id }}" ]]; then | |
| echo "Expected comment not found" | |
| exit 1 | |
| fi | |
| - name: Assert PR Comment contains expected goals | |
| env: | |
| GH_TOKEN: ${{ github.token }} | |
| run: | | |
| trimmedComment=$(echo "${{ steps.fc.outputs.comment-body }}" | sed 's/^ *//g') | |
| if [[ ! "$trimmedComment" == *clean* ]]; then | |
| echo "Publication summary does not contain clean goals" | |
| exit 1 | |
| fi | |
| if [[ ! "$trimmedComment" == *initialize* ]]; then | |
| echo "Publication summary does not contain initialize goals" | |
| exit 1 | |
| fi |