Skip to content

Commit 5723a7f

Browse files
authored
ci: centralize update-readme workflow (#161)
1 parent 16677d5 commit 5723a7f

File tree

6 files changed

+10
-396
lines changed

6 files changed

+10
-396
lines changed
Lines changed: 7 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,13 @@
1-
name: Data Fetch
1+
name: update-readme
22

33
on:
44
schedule:
5-
- cron: "0 8 * * *" # Every day at 1am PDT
5+
- cron: "0 8 * * *" # Runs every day at 08:00 AM UTC
6+
67
workflow_dispatch:
78

89
jobs:
9-
build:
10-
runs-on: ubuntu-latest
11-
steps:
12-
- name: Check out repo
13-
uses: actions/checkout@v5
14-
with:
15-
token: ${{ secrets.WORKFLOW_PUSH_BOT_TOKEN }}
16-
17-
- name: Set up Node.js
18-
uses: actions/setup-node@v5
19-
20-
- name: Install npm packages
21-
run: npm install
22-
23-
- name: Update README with latest sponsor data
24-
run: npm run build:readme
25-
26-
- name: Setup Git
27-
run: |
28-
git config user.name "GitHub Actions Bot"
29-
git config user.email "<[email protected]>"
30-
- name: Save updated files
31-
run: |
32-
chmod +x ./tools/commit-readme.sh
33-
./tools/commit-readme.sh
10+
update-readme:
11+
uses: eslint/workflows/.github/workflows/update-readme.yml@main
12+
secrets:
13+
workflow_push_bot_token: ${{ secrets.WORKFLOW_PUSH_BOT_TOKEN }}

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,3 +24,6 @@ npm-debug.log*
2424

2525
# typescript
2626
*.tsbuildinfo
27+
28+
# Automatically generated files by GitHub Actions workflow
29+
tools/update-readme.js

0 commit comments

Comments
 (0)