Skip to content

Commit

Permalink
simplify the concurrency group (#18309)
Browse files Browse the repository at this point in the history
* simplify the concurrency group

* empty
  • Loading branch information
altendky authored Aug 19, 2024
1 parent 0a76e22 commit 1bebbdc
Show file tree
Hide file tree
Showing 16 changed files with 16 additions and 31 deletions.
3 changes: 1 addition & 2 deletions .github/workflows/benchmarks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,7 @@ on:
- "**"

concurrency:
# SHA is added to the end if on `main` to let all main workflows run
group: ${{ github.ref }}-${{ github.workflow }}-${{ github.event_name }}-${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release/') || startsWith(github.ref, 'refs/heads/long_lived/')) && github.sha || '' }}
group: ${{ github.event_name == 'pull_request' && format('{0}-{1}', github.event.workflow, github.event.pull_request.number) || github.run_id }}
cancel-in-progress: true

jobs:
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/build-linux-installer-deb.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@ on:
- "**"

concurrency:
# SHA is added to the end if on `main` to let all main workflows run
group: ${{ github.ref }}-${{ github.workflow }}-${{ github.event_name }}-${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release/') || startsWith(github.ref, 'refs/heads/long_lived/')) && github.sha || '' }}
group: ${{ github.event_name == 'pull_request' && format('{0}-{1}', github.event.workflow, github.event.pull_request.number) || github.run_id }}
cancel-in-progress: true

permissions:
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/build-linux-installer-rpm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@ on:
- "**"

concurrency:
# SHA is added to the end if on `main` to let all main workflows run
group: ${{ github.ref }}-${{ github.workflow }}-${{ github.event_name }}-${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release/') || startsWith(github.ref, 'refs/heads/long_lived/')) && github.sha || '' }}
group: ${{ github.event_name == 'pull_request' && format('{0}-{1}', github.event.workflow, github.event.pull_request.number) || github.run_id }}
cancel-in-progress: true

permissions:
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/build-macos-installers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@ on:
- "**"

concurrency:
# SHA is added to the end if on `main` to let all main workflows run
group: ${{ github.ref }}-${{ github.workflow }}-${{ github.event_name }}-${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release/') || startsWith(github.ref, 'refs/heads/long_lived/')) && github.sha || '' }}
group: ${{ github.event_name == 'pull_request' && format('{0}-{1}', github.event.workflow, github.event.pull_request.number) || github.run_id }}
cancel-in-progress: true

permissions:
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/build-windows-installer.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@ on:
- "**"

concurrency:
# SHA is added to the end if on `main` to let all main workflows run
group: ${{ github.ref }}-${{ github.workflow }}-${{ github.event_name }}-${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release/') || startsWith(github.ref, 'refs/heads/long_lived/')) && github.sha || '' }}
group: ${{ github.event_name == 'pull_request' && format('{0}-{1}', github.event.workflow, github.event.pull_request.number) || github.run_id }}
cancel-in-progress: true

permissions:
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/check-commit-signing.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,7 @@ on:
- "**"

concurrency:
# SHA is added to the end if on `main` to let all main workflows run
group: ${{ github.ref }}-${{ github.workflow }}-${{ github.event_name }}-${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release/') || startsWith(github.ref, 'refs/heads/long_lived/')) && github.sha || '' }}
group: ${{ github.event_name == 'pull_request' && format('{0}-{1}', github.event.workflow, github.event.pull_request.number) || github.run_id }}
cancel-in-progress: true

jobs:
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/check_wheel_availability.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,7 @@ on:
- "**"

concurrency:
# SHA is added to the end if on `main` to let all main workflows run
group: ${{ github.ref }}-${{ github.workflow }}-${{ github.event_name }}-${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release/') || startsWith(github.ref, 'refs/heads/long_lived/')) && github.sha || '' }}
group: ${{ github.event_name == 'pull_request' && format('{0}-{1}', github.event.workflow, github.event.pull_request.number) || github.run_id }}
cancel-in-progress: true

jobs:
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,7 @@ on:
- cron: "34 14 * * 3"

concurrency:
# SHA is added to the end if on `main` to let all main workflows run
group: ${{ github.ref }}-${{ github.workflow }}-${{ github.event_name }}-${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release/') || startsWith(github.ref, 'refs/heads/long_lived/')) && github.sha || '' }}
group: ${{ github.event_name == 'pull_request' && format('{0}-{1}', github.event.workflow, github.event.pull_request.number) || github.run_id }}
cancel-in-progress: true

jobs:
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/pre-commit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,7 @@ on:
- "release/**"

concurrency:
# SHA is added to the end if on `main` to let all main workflows run
group: ${{ github.ref }}-${{ github.workflow }}-${{ github.event_name }}-${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release/') || startsWith(github.ref, 'refs/heads/long_lived/')) && github.sha || '' }}
group: ${{ github.event_name == 'pull_request' && format('{0}-{1}', github.event.workflow, github.event.pull_request.number) || github.run_id }}
cancel-in-progress: true

jobs:
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/super-linter.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,7 @@ on:
- "**"

concurrency:
# SHA is added to the end if on `main` to let all main workflows run
group: ${{ github.ref }}-${{ github.workflow }}-${{ github.event_name }}-${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release/') || startsWith(github.ref, 'refs/heads/long_lived/')) && github.sha || '' }}
group: ${{ github.event_name == 'pull_request' && format('{0}-{1}', github.event.workflow, github.event.pull_request.number) || github.run_id }}
cancel-in-progress: true

###############
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/test-install-scripts.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@ on:
- "**"

concurrency:
# SHA is added to the end if on `main` to let all main workflows run
group: ${{ github.ref }}-${{ github.workflow }}-${{ github.event_name }}-${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release/') || startsWith(github.ref, 'refs/heads/long_lived/')) && github.sha || '' }}
group: ${{ github.event_name == 'pull_request' && format('{0}-{1}', github.event.workflow, github.event.pull_request.number) || github.run_id }}
cancel-in-progress: true

jobs:
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/test-single.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,7 @@ on:
default: true

concurrency:
# SHA is added to the end if on `main` to let all main workflows run
group: ${{ github.ref }}-${{ github.workflow }}-${{ inputs.concurrency-name }}-${{ github.event_name == 'workflow_dispatch' && github.run_id || '' }}-${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release/') || startsWith(github.ref, 'refs/heads/long_lived/')) && github.sha || '' }}
group: ${{ inputs.concurrency-name }}-${{ github.event_name == 'pull_request' && format('{0}-{1}', github.event.workflow, github.event.pull_request.number) || github.run_id }}
cancel-in-progress: true

defaults:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ on:
- cron: "0 13 * * *"

concurrency:
group: ${{ github.ref }}-${{ github.workflow }}-${{ github.event_name }}-${{ github.event_name == 'workflow_dispatch' && github.run_id || '' }}-${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release/') || startsWith(github.ref, 'refs/heads/long_lived/')) && github.sha || '' }}
group: ${{ github.event_name == 'pull_request' && format('{0}-{1}', github.event.workflow, github.event.pull_request.number) || github.run_id }}
cancel-in-progress: true

jobs:
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/trigger-docker-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,7 @@ on:
- "**.md"

concurrency:
# SHA is added to the end if on `main` to let all main workflows run
group: ${{ github.ref }}-${{ github.workflow }}-${{ github.event_name }}-${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release/') || startsWith(github.ref, 'refs/heads/long_lived/')) && github.sha || '' }}
group: ${{ github.event_name == 'pull_request' && format('{0}-{1}', github.event.workflow, github.event.pull_request.number) || github.run_id }}
cancel-in-progress: true

permissions:
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/trigger-docker-main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,7 @@ on:
- main

concurrency:
# SHA is added to the end if on `main` to let all main workflows run
group: ${{ github.ref }}-${{ github.workflow }}-${{ github.event_name }}-${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release/') || startsWith(github.ref, 'refs/heads/long_lived/')) && github.sha || '' }}
group: ${{ github.event_name == 'pull_request' && format('{0}-{1}', github.event.workflow, github.event.pull_request.number) || github.run_id }}
cancel-in-progress: true

permissions:
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/upload-pypi-source.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@ on:
- "**"

concurrency:
# SHA is added to the end if on `main` to let all main workflows run
group: ${{ github.ref }}-${{ github.workflow }}-${{ github.event_name }}-${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release/') || startsWith(github.ref, 'refs/heads/long_lived/')) && github.sha || '' }}
group: ${{ github.event_name == 'pull_request' && format('{0}-{1}', github.event.workflow, github.event.pull_request.number) || github.run_id }}
cancel-in-progress: true

permissions:
Expand Down

0 comments on commit 1bebbdc

Please sign in to comment.