From 3d21c50c8406384fc6924b935170d84077079104 Mon Sep 17 00:00:00 2001 From: 6574114 Date: Tue, 26 Nov 2024 12:59:17 +0100 Subject: [PATCH] - Cancel any previous workflow runs - Upload testing to codecov --- .github/workflows/00develop.yml | 2 ++ .github/workflows/autoformatting.yml | 5 +++++ .github/workflows/pin_requirements.yml | 4 ++-- .github/workflows/testing.yml | 5 +++++ 4 files changed, 14 insertions(+), 2 deletions(-) diff --git a/.github/workflows/00develop.yml b/.github/workflows/00develop.yml index 8e8b4d6a1..e8c0b5c7c 100644 --- a/.github/workflows/00develop.yml +++ b/.github/workflows/00develop.yml @@ -4,10 +4,12 @@ on: pull_request: branches: - 'develop' + push: jobs: pin_requirements: uses: ./.github/workflows/pin_requirements.yml + secrets: inherit autoformatting: needs: pin_requirements uses: ./.github/workflows/autoformatting.yml diff --git a/.github/workflows/autoformatting.yml b/.github/workflows/autoformatting.yml index 6b1a6b362..9fe158a33 100644 --- a/.github/workflows/autoformatting.yml +++ b/.github/workflows/autoformatting.yml @@ -3,6 +3,11 @@ name: Autoformatting on: workflow_call: +# Cancel any in-progress runs when a new run is triggered +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + jobs: lint: runs-on: ubuntu-latest diff --git a/.github/workflows/pin_requirements.yml b/.github/workflows/pin_requirements.yml index abc1d4217..db13f51cf 100644 --- a/.github/workflows/pin_requirements.yml +++ b/.github/workflows/pin_requirements.yml @@ -16,6 +16,7 @@ jobs: uses: actions/checkout@v4 with: ref: ${{ github.head_ref }} + token: ${{ secrets.PAT_TOKEN }} - name: Set up Python uses: actions/setup-python@v4 @@ -33,8 +34,7 @@ jobs: - name: Commit and push changes run: | - git config user.name "GitHub Actions" - git config user.email "actions@github.com" + git config user.email "AdOpT-Development@solisservices.onmicrosoft.com" git add requirements.txt git commit -m "Update requirements.txt generated by Poetry" git push \ No newline at end of file diff --git a/.github/workflows/testing.yml b/.github/workflows/testing.yml index 38bce4571..e228f3c8d 100644 --- a/.github/workflows/testing.yml +++ b/.github/workflows/testing.yml @@ -3,6 +3,11 @@ name: Testing on: workflow_call: +# Cancel any in-progress runs when a new run is triggered +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + jobs: test: runs-on: ${{ matrix.os }}