Browse Source

Enhance GitHub workflows: add concurrency settings to angular.yml, build-and-test.yml, codeql-analysis.yml, and image-compression.yml; update cancel-workflow.yml comments

Co-authored-by: Copilot <copilot@github.com>
pull/25322/head
selmankoc 2 weeks ago
parent
commit
9af9b865b7
  1. 5
      .github/workflows/angular.yml
  2. 7
      .github/workflows/build-and-test.yml
  3. 4
      .github/workflows/cancel-workflow.yml
  4. 4
      .github/workflows/codeql-analysis.yml
  5. 7
      .github/workflows/image-compression.yml

5
.github/workflows/angular.yml

@ -15,6 +15,11 @@ on:
- synchronize - synchronize
- reopened - reopened
- ready_for_review - ready_for_review
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
permissions: permissions:
contents: read contents: read

7
.github/workflows/build-and-test.yml

@ -23,6 +23,7 @@ on:
pull_request: pull_request:
branches: branches:
- dev - dev
- 'rel-*'
paths: paths:
- 'framework/**/*.cs' - 'framework/**/*.cs'
- 'framework/**/*.cshtml' - 'framework/**/*.cshtml'
@ -51,6 +52,7 @@ concurrency:
permissions: permissions:
contents: read contents: read
id-token: write
jobs: jobs:
build-test: build-test:
@ -58,7 +60,7 @@ jobs:
timeout-minutes: 50 timeout-minutes: 50
if: ${{ !github.event.pull_request.draft }} if: ${{ !github.event.pull_request.draft }}
steps: steps:
- uses: jlumbroso/free-disk-space@v1 - uses: jlumbroso/free-disk-space@v1.3.1
- uses: actions/checkout@v4 - uses: actions/checkout@v4
- uses: actions/setup-dotnet@v4 - uses: actions/setup-dotnet@v4
with: with:
@ -81,7 +83,8 @@ jobs:
shell: pwsh shell: pwsh
- name: Codecov - name: Codecov
if: ${{ github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository }}
uses: codecov/codecov-action@v5 uses: codecov/codecov-action@v5
with: with:
token: ${{ secrets.CODECOV_TOKEN }} use_oidc: true
fail_ci_if_error: true fail_ci_if_error: true

4
.github/workflows/cancel-workflow.yml

@ -1,6 +1,6 @@
# This workflow is intentionally disabled. # This workflow is intentionally disabled.
# Cancellation of redundant runs is now handled natively via the `concurrency` # The workflows that previously depended on this file now handle cancellation
# block defined in each individual workflow (e.g. build-and-test.yml). # natively via per-workflow `concurrency` blocks.
# The styfle/cancel-workflow-action has been archived upstream and is no longer maintained. # The styfle/cancel-workflow-action has been archived upstream and is no longer maintained.
# #
# To re-enable manual cancellation, change `on: workflow_dispatch` back to `on: [push]` # To re-enable manual cancellation, change `on: workflow_dispatch` back to `on: [push]`

4
.github/workflows/codeql-analysis.yml

@ -29,6 +29,10 @@ on:
- reopened - reopened
- ready_for_review - ready_for_review
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
permissions: permissions:
contents: read contents: read

7
.github/workflows/image-compression.yml

@ -12,6 +12,11 @@ on:
- synchronize - synchronize
- reopened - reopened
- ready_for_review - ready_for_review
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs: jobs:
build: build:
if: github.event.pull_request.head.repo.full_name == github.repository && !github.event.pull_request.draft if: github.event.pull_request.head.repo.full_name == github.repository && !github.event.pull_request.draft
@ -23,5 +28,3 @@ jobs:
- name: Compress Images - name: Compress Images
uses: calibreapp/image-actions@main uses: calibreapp/image-actions@main
with:
githubToken: ${{ secrets.GITHUB_TOKEN }}

Loading…
Cancel
Save