-
Notifications
You must be signed in to change notification settings - Fork 12
47 lines (39 loc) · 1.21 KB
/
Copy pathupdate-contributors.yml
File metadata and controls
47 lines (39 loc) · 1.21 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
name: Automate Contributors README Update
on:
pull_request:
types: [closed]
branches: [main]
permissions:
contents: write
concurrency:
group: update-contributors
cancel-in-progress: false
jobs:
update-readme:
if: github.event.pull_request.merged == true
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
ref: main
fetch-depth: 0
token: ${{ secrets.GH_PAT }}
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: "24"
- name: Update README and contributors leaderboard
env:
GITHUB_EVENT_PATH: ${{ github.event_path }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITHUB_DEFAULT_BRANCH: main
run: node .github/scripts/update-contributors.js
- name: Commit changes
uses: stefanzweifel/git-auto-commit-action@v7
with:
commit_message: "docs: update contributors leaderboard [skip ci]"
file_pattern: "README.md contributors.json"
branch: main
commit_user_name: "github-actions[bot]"
commit_user_email: "github-actions[bot]@users.noreply.github.com"