From 240c679f7d22256025a7596e9854d5d4571f5361 Mon Sep 17 00:00:00 2001 From: Mike Henry <11765982+mikemhenry@users.noreply.github.com> Date: Fri, 15 Sep 2023 08:52:03 -0700 Subject: [PATCH] kill jobs if another push is made, also set the same shell for all steps --- .github/workflows/CI.yaml | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/.github/workflows/CI.yaml b/.github/workflows/CI.yaml index 3ccbf3db..2554541c 100644 --- a/.github/workflows/CI.yaml +++ b/.github/workflows/CI.yaml @@ -15,6 +15,14 @@ on: # (from https://help.github.com/en/actions/reference/events-that-trigger-workflows#scheduled-events-schedule) - cron: "0 0 * * 0" +concurrency: + group: "${{ github.workflow }}-${{ github.ref }}" + cancel-in-progress: true + +defaults: + run: + shell: bash -l {0} + jobs: test: name: Test on ${{ matrix.os }}, Python ${{ matrix.python-version }} @@ -64,7 +72,6 @@ jobs: - uses: actions/checkout@v3 - name: Additional info about the build - shell: bash run: | uname -a df -h @@ -81,14 +88,12 @@ jobs: - name: Install package # conda setup requires this special shell - shell: bash -l {0} run: | python -m pip install . --no-deps micromamba list - name: Run tests # conda setup requires this special shell - shell: bash -l {0} run: | pytest -v --cov=modelforge --cov-report=xml --color=yes modelforge/tests/