Skip to content

Commit 5295c05

Browse files
authored
ci: Allow concurrent CI runs on main (#7031)
## Explanation Fixes an issue where CI runs on main would be cancelled if there is a newer commit, despite `cancel-in-progress` being set to `false`. ## References MetaMask/metamask-mobile#21893 ## Checklist - [ ] I've updated the test suite for new or updated code as appropriate - [ ] I've updated documentation (JSDoc, Markdown, etc.) for new or updated code as appropriate - [ ] I've communicated my changes to consumers by [updating changelogs for packages I've changed](https://github.com/MetaMask/core/tree/main/docs/contributing.md#updating-changelogs), highlighting breaking changes as necessary - [ ] I've prepared draft pull requests for clients and consumer packages to resolve any breaking changes <!-- CURSOR_SUMMARY --> --- > [!NOTE] > Update workflow concurrency group to use commit SHA on main, differentiating runs on main while keeping existing cancel-in-progress logic. > > - **CI / GitHub Actions** > - **Concurrency**: Update `concurrency.group` in `.github/workflows/main.yml` to `${{ github.workflow }}-${{ github.ref == 'refs/heads/main' && github.sha || github.ref }}` to use `github.sha` on `main` and `github.ref` otherwise. > - `cancel-in-progress` remains `${{ !contains(github.ref, 'refs/heads/main') }}`. > > <sup>Written by [Cursor Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit ea221a5. This will update automatically on new commits. Configure [here](https://cursor.com/dashboard?tab=bugbot).</sup> <!-- /CURSOR_SUMMARY -->
1 parent e339c79 commit 5295c05

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

.github/workflows/main.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ on:
66
pull_request:
77

88
concurrency:
9-
group: ${{ github.workflow }}-${{ github.ref }}
9+
group: ${{ github.workflow }}-${{ github.ref == 'refs/heads/main' && github.sha || github.ref }}
1010
cancel-in-progress: ${{ !contains(github.ref, 'refs/heads/main') }}
1111

1212
jobs:

0 commit comments

Comments
 (0)