Update GitHub workflows: enhance build-and-test.yml with concurrency and caching#25322
Update GitHub workflows: enhance build-and-test.yml with concurrency and caching#25322
Conversation
…and caching, and disable cancel-workflow.yml
…ild-and-test.yml, codeql-analysis.yml, and image-compression.yml; update cancel-workflow.yml comments Co-authored-by: Copilot <copilot@github.com>
There was a problem hiding this comment.
Pull request overview
This PR updates GitHub Actions workflows to handle run cancellation via native concurrency blocks (replacing the archived cancel-workflow action) and modernizes parts of the CI workflow configuration.
Changes:
- Add
concurrencyblocks to several workflows to auto-cancel in-progress runs on new pushes/updates. - Disable the legacy
cancel-workflowworkflow (styfle action archived upstream). - Update
build-and-testworkflow actions, add NuGet caching, and switch Codecov upload to OIDC with conditional execution.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| .github/workflows/image-compression.yml | Adds native concurrency; removes explicit token input for image compression action. |
| .github/workflows/codeql-analysis.yml | Adds native concurrency to CodeQL workflow. |
| .github/workflows/cancel-workflow.yml | Disables legacy cancellation workflow and replaces it with a no-op. |
| .github/workflows/build-and-test.yml | Adds concurrency, updates action versions, adds NuGet cache, updates Codecov upload configuration. |
| .github/workflows/angular.yml | Adds native concurrency to Angular workflow. |
| @@ -23,5 +28,3 @@ jobs: | |||
|
|
|||
| - name: Compress Images | |||
| uses: calibreapp/image-actions@main | |||
There was a problem hiding this comment.
calibreapp/image-actions@main is referenced by a moving branch, which is a supply-chain risk and can make builds non-reproducible if upstream changes. Pin this to a tagged release or a specific commit SHA instead of main.
| uses: calibreapp/image-actions@main | |
| uses: calibreapp/image-actions@1.0.0 |
| steps: | ||
| - uses: jlumbroso/free-disk-space@main | ||
| - uses: PSModule/install-powershell@v1 | ||
| with: | ||
| Version: latest | ||
| - uses: actions/checkout@v2 | ||
| - uses: actions/setup-dotnet@master | ||
| - uses: jlumbroso/free-disk-space@v1.3.1 | ||
| - uses: actions/checkout@v4 | ||
| - uses: actions/setup-dotnet@v4 |
There was a problem hiding this comment.
The steps: list items are not indented under steps: (they start at the same indentation level as steps:). This makes the workflow YAML invalid and will prevent the job from running. Indent each - uses: / - name: line (and its children) under steps:.
No description provided.