From aba90502d479abeb5b86885a94637ef64f0fc57a Mon Sep 17 00:00:00 2001 From: DaanV2 Date: Tue, 14 Oct 2025 19:57:26 +0200 Subject: [PATCH] fix: adding a check --- .github/workflows/compress-json-schemas.yml | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/.github/workflows/compress-json-schemas.yml b/.github/workflows/compress-json-schemas.yml index 5341f195..b58f786c 100644 --- a/.github/workflows/compress-json-schemas.yml +++ b/.github/workflows/compress-json-schemas.yml @@ -36,12 +36,17 @@ jobs: with: specificationFile: "source/compress_specification.json" - - name: ✏️ Commit changes - continue-on-error: true + - name: ✏️ Commit and push changes (if any) run: | - cd ${{github.workspace}} + cd "${{ github.workspace }}" git config --global user.email "orbi@blockception.com" git config --global user.name "Orbi-bot" git add . - git commit -m "auto: generated json schemas ${{ steps.time.outputs.time }}" - git push + if ! git diff --cached --quiet; then + echo "📝 Changes detected, committing..." + git commit -m "auto: generated json schemas ${{ steps.time.outputs.time }}" + echo "🚀 Pushing changes..." + git push + else + echo "✅ No changes to commit." + fi