Fix documentation workflow always trying to commit
Don't try to commit and push if there is nothing to commit, because git will exit with 1, failing the workflow.
A continuation of ca6b87d05e.
This commit is contained in:
2
.github/workflows/documentation.yml
vendored
2
.github/workflows/documentation.yml
vendored
@@ -87,6 +87,7 @@ jobs:
|
||||
cd wiki
|
||||
git config --local user.email "actions@github.com"
|
||||
git config --local user.name "GitHub Actions"
|
||||
git status
|
||||
git diff-index --quiet HEAD || \
|
||||
(
|
||||
git add --all && \
|
||||
@@ -140,6 +141,7 @@ jobs:
|
||||
cd docs
|
||||
git config --local user.email "actions@github.com"
|
||||
git config --local user.name "GitHub Actions"
|
||||
git status
|
||||
git diff-index --quiet HEAD || \
|
||||
(
|
||||
git add api/*.md && \
|
||||
|
||||
Reference in New Issue
Block a user