From ec9a16e56015b246e597e8337f8109a28825cc6c Mon Sep 17 00:00:00 2001 From: Mathew Payne <2772944+GeekMasher@users.noreply.github.com> Date: Thu, 5 Sep 2024 17:37:43 +0000 Subject: [PATCH] feat: Update Python vendor workflow --- .github/workflows/python-vendor.yml | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/.github/workflows/python-vendor.yml b/.github/workflows/python-vendor.yml index c7267d0..08b408c 100644 --- a/.github/workflows/python-vendor.yml +++ b/.github/workflows/python-vendor.yml @@ -3,7 +3,6 @@ name: Python - Vendoring on: push: - pull_request: workflow_call: inputs: custom-property: @@ -48,6 +47,9 @@ jobs: runs-on: ubuntu-latest needs: [ custom-property ] if: ${{ needs.custom-property.outputs.osstype == 'Actions' }} + permissions: + contents: write + pull-requests: write steps: - name: Checkout uses: actions/checkout@v4 @@ -76,15 +78,14 @@ jobs: CHANGES=$(git status --porcelain | wc -l) echo "changes=$CHANGES" >> "$GITHUB_OUTPUT" - - name: "Update vendored dependencies (Push)" - if: ${{ steps.vendoring.outputs.changes != 0 && (github.event_name == 'push' || github.event_name == 'workflow_dispatch') }} + - name: "Create Pull Request with updated vendored dependencies" + if: ${{ steps.vendoring.outputs.changes > 0 }} uses: peter-evans/create-pull-request@v6 with: token: ${{ github.token }} commit-message: "[chore]: Update vendored dependencies" title: "[chore]: Update vendored dependencies" branch: update-vendored-dependencies - base: ${{ github.event.before }} labels: dependencies body: | This is an automated PR to update that vendored dependencies are up to date.