Create h0yd49.json #3
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: Merge Contributors | |
| on: | |
| push: | |
| paths: | |
| - 'src/data/*.json' | |
| - '!src/data/contributors.json' | |
| pull_request: | |
| paths: | |
| - 'src/data/*.json' | |
| - '!src/data/contributors.json' | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: '20' | |
| - run: npm install | |
| - run: npm run merge | |
| - name: Commit and push if changed | |
| run: | | |
| git config --global user.name 'github-actions[bot]' | |
| git config --global user.email 'github-actions[bot]@users.noreply.github.com' | |
| git add src/data/contributors.json | |
| git diff --cached --quiet || git commit -m "Auto-merge contributors" | |
| git push |