Skip to content

Commit 9f63e1d

Browse files
committed
ci: no prev demos is not an error
1 parent 54e75a7 commit 9f63e1d

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

.github/workflows/ci.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -668,6 +668,7 @@ jobs:
668668
if: startsWith(github.ref, 'refs/tags/') && runner.os == 'Linux'
669669
id: download-prev-demos
670670
uses: actions/download-artifact@v4
671+
continue-on-error: true
671672
with:
672673
name: demos-develop-${{ runner.os }}
673674
path: demos-previous
@@ -682,6 +683,13 @@ jobs:
682683
LOCAL_DEMOS_DIR="./demos/"
683684
PREV_DEMOS_DIR="./demos-previous/"
684685
DIFF_DIR="./demos-diff/"
686+
687+
# Check if PREV_DEMOS_DIR exists and is not empty
688+
if [[ ! -d $PREV_DEMOS_DIR || -z $(ls -A $PREV_DEMOS_DIR) ]]; then
689+
echo "No previous demos found."
690+
echo "diff=false" >> $GITHUB_OUTPUT
691+
exit 0
692+
fi
685693
686694
# Create directories if they don't exist
687695
mkdir -p $PREV_DEMOS_DIR $DIFF_DIR

0 commit comments

Comments
 (0)