Fix actions failure when there are no new contributors

This commit is contained in:
Timmy Welch 2023-02-17 13:43:41 -08:00
parent c437532622
commit 628dd5e456
No known key found for this signature in database

View File

@ -34,8 +34,10 @@ jobs:
- name: Commit and push AUTHORS
run: |
git pull
git config --global user.name "${{ env.CI_COMMIT_AUTHOR }}"
git config --global user.email "${{ env.CI_COMMIT_EMAIL }}"
git commit -a -m "${{ env.CI_COMMIT_MESSAGE }}"
git push
if ! git diff --exit-code; then
git pull
git config --global user.name "${{ env.CI_COMMIT_AUTHOR }}"
git config --global user.email "${{ env.CI_COMMIT_EMAIL }}"
git commit -a -m "${{ env.CI_COMMIT_MESSAGE }}"
git push
fi