-
Notifications
You must be signed in to change notification settings - Fork 426
44 lines (35 loc) · 1.08 KB
/
Copy pathenrich-projects.yml
File metadata and controls
44 lines (35 loc) · 1.08 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
name: Enrich Projects
on:
schedule:
# Every Monday at 02:00 UTC
- cron: "0 2 * * 1"
workflow_dispatch: {}
permissions:
contents: write
pull-requests: write
jobs:
enrich:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20
- name: Install dependencies
run: npm ci
- name: Run enrichment
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: node scripts/enrich-projects.mjs
- name: Check for changes
id: diff
run: |
git diff --quiet data/projects.enriched.json && echo "changed=false" >> $GITHUB_OUTPUT || echo "changed=true" >> $GITHUB_OUTPUT
- name: Commit enriched data
if: steps.diff.outputs.changed == 'true'
run: |
git config user.name "github-actions[bot]"
git config user.email "github-actions[bot]@users.noreply.github.com"
git add data/projects.enriched.json
git commit -m "chore: update enriched project data [skip ci]"
git push