Skip to content

Commit 661d2af

Browse files
author
root
committed
fix(verify): skip docs->site cmp when site directory is missing
1 parent 1cbc0e8 commit 661d2af

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

.github/scripts/verify-site-scripts.sh

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -63,10 +63,12 @@ for f in "${files_to_check[@]}"; do
6363
EXIT_CODE=1
6464
continue
6565
fi
66-
# Compare content
67-
if ! cmp -s "$docf" "$sitef"; then
68-
echo "DIFF: $base differs between docs and site"
69-
EXIT_CODE=1
66+
# Compare content (only if site copied files exist)
67+
if [[ -d "$SITE_DIR" ]]; then
68+
if ! cmp -s "$docf" "$sitef"; then
69+
echo "DIFF: $base differs between docs and site"
70+
EXIT_CODE=1
71+
fi
7072
fi
7173
# Verify sha file entry
7274
sha_expected=$(sha256sum "$docf" | awk '{print $1}')

0 commit comments

Comments
 (0)