Repository navigation
Composer: leave a file the browser names as another format to the server #195
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: Release note edited | |
| # A pull request's release note is in its description (scripts/release-note-check.ts), and editing a | |
| # description starts no CI run. So when the description changes after CI's run of the pull request's | |
| # head has finished with its `release note` check failed or cancelled, this re-runs that run's failed | |
| # jobs (scripts/release-note-edited.ts): the check reads the description again, and `verify` follows | |
| # it. A failing check stops its own run (.github/actions/stop-on-failure), which cancels the check's | |
| # job too, so a failed check most often reports cancelled. Nothing else runs again, since every | |
| # other job of the run passed or is re-run only because it failed or was cancelled. While the run is | |
| # still going, nothing is needed: the check runs last and reads the description then. | |
| # | |
| # Pull requests from this repository: a fork's token is read-only and cannot re-run. A maintainer | |
| # re-runs a fork's failed jobs by hand. | |
| on: | |
| pull_request: | |
| types: [edited] | |
| permissions: {} | |
| concurrency: | |
| group: release-note-edited-${{ github.event.pull_request.number }} | |
| cancel-in-progress: true | |
| jobs: | |
| rerun: | |
| name: re-run the release note | |
| if: >- | |
| github.event.pull_request.head.repo.full_name == github.repository && | |
| github.event.changes.body != null | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 5 # seconds | |
| permissions: | |
| # To check out the script. | |
| contents: read | |
| # To read CI's runs and re-run one. | |
| actions: write | |
| steps: | |
| - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | |
| with: | |
| persist-credentials: false | |
| sparse-checkout: scripts/release-note-edited.ts | |
| sparse-checkout-cone-mode: false | |
| - uses: oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6 # v2.2.0 | |
| with: | |
| bun-version: 1.4.3 | |
| no-cache: true | |
| - name: Re-run CI's failed or cancelled release note on the pull request's head | |
| env: | |
| GH_TOKEN: ${{ github.token }} | |
| REPOSITORY: ${{ github.repository }} | |
| HEAD_SHA: ${{ github.event.pull_request.head.sha }} | |
| run: bun scripts/release-note-edited.ts |