Add Winky to Consumer Applications #3
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: All Contributors | |
| on: | |
| pull_request_target: | |
| types: [closed] | |
| jobs: | |
| add-contributor: | |
| if: github.event.pull_request.merged == true | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: write | |
| pull-requests: write | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| ref: main | |
| fetch-depth: 0 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20 | |
| - name: Add contributor | |
| run: | | |
| npx all-contributors-cli add ${{ github.event.pull_request.user.login }} code | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Commit and push changes | |
| run: | | |
| git config --global user.name "github-actions[bot]" | |
| git config --global user.email "github-actions[bot]@users.noreply.github.com" | |
| git add .all-contributorsrc README.md | |
| git diff --staged --quiet || git commit -m "docs: add ${{ github.event.pull_request.user.login }} as a contributor" | |
| git push |