From f1589798fb1f37972388c70f519bf26a72498359 Mon Sep 17 00:00:00 2001 From: DevMirza <53424436+Zaid-maker@users.noreply.github.com> Date: Sat, 4 May 2024 22:58:27 +0500 Subject: [PATCH] check if directory exits --- .github/workflows/bench-turbopack.yml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/bench-turbopack.yml b/.github/workflows/bench-turbopack.yml index 50d7ed7504385..ea4590fe925a2 100644 --- a/.github/workflows/bench-turbopack.yml +++ b/.github/workflows/bench-turbopack.yml @@ -294,7 +294,11 @@ jobs: - name: Copy benchmark results run: | - find artifacts -size 0 -delete + if [ ! -d artifacts ]; then + echo "Artifacts directory not found. Skipping copy." + exit 0 + fi + find artifacts -size 0 -delete || true mkdir -p data/${{ steps.date.outputs.year }}/${{ steps.date.outputs.month }}/ubuntu-latest-8-core/${{ steps.date.outputs.date }}-${{ github.sha }}/ mv artifacts/bench_* data/${{ steps.date.outputs.year }}/${{ steps.date.outputs.month }}/ubuntu-latest-8-core/${{ steps.date.outputs.date }}-${{ github.sha }}/