Skip to content

Commit 8dc0a21

Browse files
committed
tests
1 parent 345393c commit 8dc0a21

1 file changed

Lines changed: 11 additions & 6 deletions

File tree

.github/workflows/build.yml

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -232,13 +232,18 @@ jobs:
232232
- run: |
233233
mkdir -p ./docs/${{ env.friendly-version }}
234234
mv ./docs/temp/** ./docs/${{ env.friendly-version }}
235-
- run: git fetch origin
236-
- run: git checkout -b docs origin/docs --force
237-
- run: git config --global user.email "action@github.com"
238-
- run: git config --global user.name "GitHub Action"
235+
- run: |
236+
git fetch origin
237+
git checkout -b docs origin/docs --force
238+
git config --global user.email "action@github.com"
239+
git config --global user.name "GitHub Action"
239240
- run: git add -- ./docs/${{ env.friendly-version }}
240-
- run: git commit -m'added ./docs/${{ env.friendly-version }}' -- ./docs/${{ env.friendly-version }}
241-
- run: git push
241+
- id: check-diff
242+
run: git diff-index --quiet --cached HEAD --
243+
- if: steps.check-diff.outcome == '1'
244+
run: |
245+
git commit -m'added ./docs/${{ env.friendly-version }}' -- ./docs/${{ env.friendly-version }}
246+
git push
242247
# - name: Upload artifact
243248
# uses: actions/upload-pages-artifact@v3
244249
# with:

0 commit comments

Comments
 (0)