diff --git a/.github/workflows/create-pr.yml b/.github/workflows/create-pr.yml index 869089c75..251e855f2 100644 --- a/.github/workflows/create-pr.yml +++ b/.github/workflows/create-pr.yml @@ -33,6 +33,12 @@ jobs: fetch-depth: 0 if: ${{ env.PR_BRANCH && env.BUILD_URL }} + - name: Skip if branch exists already + run: | + set -e + git fetch origin ${{ env.PR_BRANCH }} || echo "Branch ${{ env.PR_BRANCH }} does not exist yet." + if: ${{ env.PR_BRANCH && env.BUILD_URL }} + - name: Insert dependency uses: Wandalen/wretry.action@master id: manipulate_composer diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 62ed57789..0a6d3c2f1 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -11,12 +11,14 @@ jobs: name: Test runs-on: ubuntu-latest steps: + - uses: actions/checkout@v4 + with: + fetch-depth: 0 - name: Testing run: | - BRANCH_EXISTS=$(git fetch origin develop || echo "John") - echo "$BRANCH_EXISTS" - # echo "BUILD_URL_IS_ACCEPTED=$BUILD_URL_IS_ACCEPTED" >> $GITHUB_ENV + echo "BRANCH_EXISTS=$(git show-ref --quiet refs/heads/abe && echo 'true' || echo 'false')" >> $GITHUB_ENV + - name: Testing II run: | - echo "Hello" + echo "${{ toJson(env) }}"