diff --git a/.github/workflows/checkin.yml b/.github/workflows/checkin.yml index 4b342a0..bcf5d0a 100644 --- a/.github/workflows/checkin.yml +++ b/.github/workflows/checkin.yml @@ -21,7 +21,9 @@ jobs: - name: "check for uncommitted changes" # Ensure no changes run: | - git add . && git diff --exit-code --stat \ - || (echo "##[error] found changed files after build. please 'yarn build && npm run format'" \ - "and check in all changes" \ - && exit 1) + git add . + if git diff --cached --stat --exit-code; then + else + echo "##[error] Found changed files after build. Please 'yarn build && npm run format' and check in all changes." + exit 1 + fi \ No newline at end of file