diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e5977dd9..b16b3a2f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -75,14 +75,14 @@ jobs: if: failure() run: | # In the case of a failure, remove the previous status, whatever it was, and update it to 1. - if [ -f status-${{ matrix.php-version }}.txt ]; then - rm status-${{ matrix.php-version }}.txt + if [ -f status-${{ matrix.php-version }}-${{ github.sha }}.txt ]; then + rm status-${{ matrix.php-version }}-${{ github.sha }}.txt fi - echo "1" > status-${{ matrix.php-version }}.txt + echo "1" > status-${{ matrix.php-version }}-${{ github.sha }}.txt - name: Create success status artifact if: success() run: | # Only create a status file if it doesn't already exist. - if [ ! -f status-${{ matrix.php-version }}.txt ]; then - echo "0" > status-${{ matrix.php-version }}.txt + if [ ! -f status-${{ matrix.php-version }}-${{ github.sha }}.txt ]; then + echo "0" > status-${{ matrix.php-version }}-${{ github.sha }}.txt fi diff --git a/.github/workflows/playwright.yml b/.github/workflows/playwright.yml index 74fa6556..eaa15f15 100644 --- a/.github/workflows/playwright.yml +++ b/.github/workflows/playwright.yml @@ -34,11 +34,11 @@ jobs: while [ $attempt -lt $max_attempts ]; do # Attempt to download the artifacts. - gh run download -n status-8.1 - gh run download -n status-8.2 - gh run download -n status-8.3 + gh run download -n status-8.1-${{ github.sha }} + gh run download -n status-8.2-${{ github.sha }} + gh run download -n status-8.3-${{ github.sha }} - if [ -f status-8.1.txt ] && [ -f status-8.2.txt ] && [ -f status-8.3.txt ]; then + if [ -f status-8.1-${{ github.sha }}.txt ] && [ -f status-8.2-${{ github.sha }}.txt ] && [ -f status-8.3-${{ github.sha }}.txt ]; then ls status-*.txt echo "All status files found." success=1 @@ -164,11 +164,11 @@ jobs: while [ $attempt -lt $max_attempts ]; do # Attempt to download the artifacts. - gh run download -n status-8.1 - gh run download -n status-8.2 - gh run download -n status-8.3 + gh run download -n status-8.1-${{ github.sha }} + gh run download -n status-8.2-${{ github.sha }} + gh run download -n status-8.3-${{ github.sha }} - if [ -f status-8.1.txt ] && [ -f status-8.2.txt ] && [ -f status-8.3.txt ]; then + if [ -f status-8.1-${{ github.sha }}.txt ] && [ -f status-8.2-${{ github.sha }}.txt ] && [ -f status-8.3-${{ github.sha }}.txt ]; then success=1 break else @@ -297,11 +297,11 @@ jobs: while [ $attempt -lt $max_attempts ]; do # Attempt to download the artifacts. - gh run download -n status-8.1 - gh run download -n status-8.2 - gh run download -n status-8.3 + gh run download -n status-8.1-${{ github.sha }} + gh run download -n status-8.2-${{ github.sha }} + gh run download -n status-8.3-${{ github.sha }} - if [ -f status-8.1.txt ] && [ -f status-8.2.txt ] && [ -f status-8.3.txt ]; then + if [ -f status-8.1-${{ github.sha }}.txt ] && [ -f status-8.2-${{ github.sha }}.txt ] && [ -f status-8.3-${{ github.sha }}.txt ]; then success=1 break else