-
Notifications
You must be signed in to change notification settings - Fork 38
50 lines (48 loc) · 1.27 KB
/
pr-stats.yml
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
50
name: "Create PR Stats"
on:
workflow_dispatch:
pull_request: # run if the file changed on a PR to rolling
branches:
- rolling
paths:
- 'make_help_scripts/create_pr_stats.py'
push: # run if the file changed by pushes to rolling
branches:
- rolling
paths:
- 'make_help_scripts/create_pr_stats.py'
schedule:
# Run every morning to ensure component documentation is up to date on deployment
- cron: '23 3 * * *'
jobs:
create-pr-stats:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: actions/setup-python@v5
with:
python-version: '3.10'
cache: 'pip'
- name: Install Python dependencies
run: |
python -m pip install --upgrade pip
pip install --upgrade --requirement requirements.txt
shell: bash
- name: Get stats
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
python make_help_scripts/create_pr_stats.py
shell: bash
- name: Cache stats
uses: actions/cache/save@v4
with:
key: reviewer-stats-${{ github.run_id }}
path: ~/reviews
- name: Upload Artifacts
uses: actions/[email protected]
with:
name: pr-stats
path: ~/reviews