Skip to content

Commit

Permalink
fixed auto contributors script to handle no changes in contributors
Browse files Browse the repository at this point in the history
  • Loading branch information
uchendui committed Sep 22, 2023
1 parent 95b2c4b commit de46fb6
Showing 1 changed file with 1 addition and 11 deletions.
12 changes: 1 addition & 11 deletions .github/workflows/auto-add-contributors.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,16 +39,6 @@ jobs:
python .github/workflows/contributors/update_contributors.py
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Committing changes to same branch
run: |
echo "Committing changes to same branch"
git config --global user.email "github-actions[bot]@users.noreply.github.com"
git config --global user.name "github-actions[bot]"
git add .all-contributorsrc
git commit -m " Update contributors from github action"
git push
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Using all-contributors CLI to update files
run: |
echo "Using all-contributors CLI to update files"
Expand All @@ -57,5 +47,5 @@ jobs:
git config --global user.email "github-actions[bot]@users.noreply.github.com"
git config --global user.name "github-actions[bot]"
git add -u
git commit -m "Update readme and contributors.qmd with contributors"
git diff-index --quiet HEAD || git commit -m "Update readme and contributors.qmd with contributors"
git push

0 comments on commit de46fb6

Please sign in to comment.