16 changed files with 151 additions and 143 deletions
@ -1,27 +1,27 @@
@@ -1,27 +1,27 @@
|
||||
name: Create GitHub Release |
||||
description: Create the release on GitHub with a changelog |
||||
description: 'Create the release on GitHub with a changelog' |
||||
inputs: |
||||
milestone: |
||||
description: Name of the GitHub milestone for which a release will be created |
||||
required: true |
||||
token: |
||||
description: Token to use for authentication with GitHub |
||||
description: 'Name of the GitHub milestone for which a release will be created' |
||||
required: true |
||||
pre-release: |
||||
description: Whether the release is a pre-release (a milestone or release candidate) |
||||
description: 'Whether the release is a pre-release (a milestone or release candidate)' |
||||
required: false |
||||
default: 'false' |
||||
token: |
||||
description: 'Token to use for authentication with GitHub' |
||||
required: true |
||||
runs: |
||||
using: composite |
||||
steps: |
||||
- name: Generate Changelog |
||||
uses: spring-io/github-changelog-generator@185319ad7eaa75b0e8e72e4b6db19c8b2cb8c4c1 #v0.0.11 |
||||
with: |
||||
config-file: .github/actions/create-github-release/changelog-generator.yml |
||||
milestone: ${{ inputs.milestone }} |
||||
token: ${{ inputs.token }} |
||||
config-file: .github/actions/create-github-release/changelog-generator.yml |
||||
- name: Create GitHub Release |
||||
shell: bash |
||||
env: |
||||
GITHUB_TOKEN: ${{ inputs.token }} |
||||
shell: bash |
||||
run: gh release create ${{ format('v{0}', inputs.milestone) }} --notes-file changelog.md ${{ inputs.pre-release == 'true' && '--prerelease' || '' }} |
||||
|
||||
@ -1,33 +1,39 @@
@@ -1,33 +1,39 @@
|
||||
name: Send Notification |
||||
description: Sends a Google Chat message as a notification of the job's outcome |
||||
description: 'Sends a Google Chat message as a notification of the job''s outcome' |
||||
inputs: |
||||
webhook-url: |
||||
description: 'Google Chat Webhook URL' |
||||
required: true |
||||
status: |
||||
description: 'Status of the job' |
||||
required: true |
||||
build-scan-url: |
||||
description: 'URL of the build scan to include in the notification' |
||||
required: false |
||||
run-name: |
||||
description: 'Name of the run to include in the notification' |
||||
required: false |
||||
default: ${{ format('{0} {1}', github.ref_name, github.job) }} |
||||
status: |
||||
description: 'Status of the job' |
||||
required: true |
||||
webhook-url: |
||||
description: 'Google Chat Webhook URL' |
||||
required: true |
||||
runs: |
||||
using: composite |
||||
steps: |
||||
- shell: bash |
||||
- name: Prepare Variables |
||||
shell: bash |
||||
run: | |
||||
echo "BUILD_SCAN=${{ inputs.build-scan-url == '' && ' [build scan unavailable]' || format(' [<{0}|Build Scan>]', inputs.build-scan-url) }}" >> "$GITHUB_ENV" |
||||
echo "RUN_URL=${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}" >> "$GITHUB_ENV" |
||||
- shell: bash |
||||
- name: Success Notification |
||||
if: ${{ inputs.status == 'success' }} |
||||
shell: bash |
||||
run: | |
||||
curl -X POST '${{ inputs.webhook-url }}' -H 'Content-Type: application/json' -d '{ text: "<${{ env.RUN_URL }}|${{ inputs.run-name }}> was successful ${{ env.BUILD_SCAN }}"}' || true |
||||
- shell: bash |
||||
- name: Failure Notification |
||||
if: ${{ inputs.status == 'failure' }} |
||||
shell: bash |
||||
run: | |
||||
curl -X POST '${{ inputs.webhook-url }}' -H 'Content-Type: application/json' -d '{ text: "<users/all> *<${{ env.RUN_URL }}|${{ inputs.run-name }}> failed* ${{ env.BUILD_SCAN }}"}' || true |
||||
- shell: bash |
||||
- name: Cancel Notification |
||||
if: ${{ inputs.status == 'cancelled' }} |
||||
shell: bash |
||||
run: | |
||||
curl -X POST '${{ inputs.webhook-url }}' -H 'Content-Type: application/json' -d '{ text: "<${{ env.RUN_URL }}|${{ inputs.run-name }}> was cancelled"}' || true |
||||
|
||||
@ -1,38 +1,36 @@
@@ -1,38 +1,36 @@
|
||||
name: Build Pull Request |
||||
on: pull_request |
||||
|
||||
permissions: |
||||
contents: read |
||||
|
||||
jobs: |
||||
build: |
||||
name: Build Pull Request |
||||
if: ${{ github.repository == 'spring-projects/spring-framework' }} |
||||
runs-on: ubuntu-latest |
||||
timeout-minutes: 60 |
||||
if: ${{ github.repository == 'spring-projects/spring-framework' }} |
||||
steps: |
||||
- name: Set up JDK 17 |
||||
- name: Set Up JDK 17 |
||||
uses: actions/setup-java@v4 |
||||
with: |
||||
java-version: '17' |
||||
distribution: 'liberica' |
||||
java-version: '17' |
||||
- name: Check Out |
||||
uses: actions/checkout@v4 |
||||
- name: Validate Gradle Wrapper |
||||
uses: gradle/actions/wrapper-validation@d9c87d481d55275bb5441eef3fe0e46805f9ef70 # v3.5.0 |
||||
uses: gradle/actions/wrapper-validation@d156388eb19639ec20ade50009f3d199ce1e2808 # v4.1.0 |
||||
- name: Set Up Gradle |
||||
uses: gradle/actions/setup-gradle@d9c87d481d55275bb5441eef3fe0e46805f9ef70 # v3.5.0 |
||||
uses: gradle/actions/setup-gradle@d156388eb19639ec20ade50009f3d199ce1e2808 # v4.1.0 |
||||
- name: Build |
||||
env: |
||||
CI: 'true' |
||||
GRADLE_ENTERPRISE_URL: 'https://ge.spring.io' |
||||
run: ./gradlew -Dorg.gradle.internal.launcher.welcomeMessageEnabled=false --no-daemon --no-parallel --continue build |
||||
- name: Print JVM Thread Dumps When Cancelled |
||||
uses: ./.github/actions/print-jvm-thread-dumps |
||||
if: cancelled() |
||||
uses: ./.github/actions/print-jvm-thread-dumps |
||||
- name: Upload Build Reports |
||||
uses: actions/upload-artifact@v4 |
||||
if: failure() |
||||
uses: actions/upload-artifact@v4 |
||||
with: |
||||
name: build-reports |
||||
path: '**/build/reports/' |
||||
|
||||
@ -1,11 +0,0 @@
@@ -1,11 +0,0 @@
|
||||
name: "Validate Gradle Wrapper" |
||||
on: [push, pull_request] |
||||
permissions: |
||||
contents: read |
||||
jobs: |
||||
validation: |
||||
name: "Validate Gradle Wrapper" |
||||
runs-on: ubuntu-latest |
||||
steps: |
||||
- uses: actions/checkout@v4 |
||||
- uses: gradle/actions/wrapper-validation@d9c87d481d55275bb5441eef3fe0e46805f9ef70 # v3.5.0 |
||||
Loading…
Reference in new issue