-
Notifications
You must be signed in to change notification settings - Fork 0
49 lines (42 loc) · 1.36 KB
/
Copy pathaggregate-feedback.yml
File metadata and controls
49 lines (42 loc) · 1.36 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
48
49
name: Aggregate Eval Feedback → community-stats
on:
schedule:
# Daily at 03:00 UTC — well after most timezones' workday close
- cron: '0 3 * * *'
workflow_dispatch:
# Manual trigger via Actions tab
issues:
types: [closed, reopened, edited]
permissions:
contents: write # to commit community-stats.md
issues: read # to read closed eval-feedback issues
jobs:
aggregate:
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Aggregate feedback
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
REPO: ${{ github.repository }}
run: |
python3 .github/scripts/aggregate_feedback.py \
--repo "$REPO" \
--output community-stats.md
- name: Commit if changed
run: |
if git diff --quiet community-stats.md; then
echo "No changes to commit."
exit 0
fi
git config user.name "github-actions[bot]"
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
git add community-stats.md
git commit -m "chore(stats): refresh community-stats from feedback issues"
git push