diff --git a/.github/workflows/lean_action_ci.yml b/.github/workflows/lean_action_ci.yml index 95bc25bd1..af9ebc99f 100644 --- a/.github/workflows/lean_action_ci.yml +++ b/.github/workflows/lean_action_ci.yml @@ -9,6 +9,13 @@ on: merge_group: workflow_dispatch: +# Label each run; only the latest run carrying a given label is kept. Pushes to +# main and nightly-testing get the run id in their label, making it unique, so +# those runs are never cancelled. +concurrency: + group: ${{ github.workflow }}-${{ github.ref }}-${{ (github.event_name == 'push' && (github.ref == 'refs/heads/main' || github.ref == 'refs/heads/nightly-testing') && github.run_id) || '' }} + cancel-in-progress: true + jobs: ci-checks: runs-on: ubuntu-latest