From 32924465e19f81c85f0631793414c173f1721822 Mon Sep 17 00:00:00 2001 From: Julia March <101819212+juliamrch@users.noreply.github.com> Date: Tue, 20 Aug 2024 16:21:41 +0200 Subject: [PATCH] chore: add condition to run checkout action to prevent errors on repos that have a delete branch on merge automation --- .github/workflows/main.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 3e1e8c5..7ef61da 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -13,6 +13,7 @@ jobs: contents: read steps: - uses: actions/checkout@v4 + if: ${{ github.event.action == 'opened' || github.event.action == 'reopened' || github.event.action == 'synchronize' }} with: repository: ${{ github.event.pull_request.head.repo.full_name }} ref: ${{ github.event.pull_request.head.ref }} @@ -29,4 +30,4 @@ jobs: with: type: 'static-apache' set-env: true - environment: 'review' + environment: 'review' \ No newline at end of file