Fixing issues/893 - git diff command fails if _dist/_ folder doesn't exist

This commit is contained in:
alexquitiaquez 2024-04-22 22:17:29 -04:00 committed by GitHub
parent cebb7a99fe
commit 857655ca74
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -50,6 +50,11 @@ jobs:
- name: Compare Directories
id: diff
run: |
if [ ! -d dist/ ]; then
echo "Expected dist/ directory does not exist. See status below:"
ls -la ./
exit 1
fi
if [ "$(git diff --ignore-space-at-eol --text dist/ | wc -l)" -gt "0" ]; then
echo "Detected uncommitted changes after build. See status below:"
git diff --ignore-space-at-eol --text dist/