forked from open-telemetry/opentelemetry-collector-contrib
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathgenerate-codeowners-activity.yml
More file actions
42 lines (39 loc) · 1.49 KB
/
Copy pathgenerate-codeowners-activity.yml
File metadata and controls
42 lines (39 loc) · 1.49 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
# This workflow generates a code owner activity report as a GitHub issue.
# It measures whether code owners have reviewed/replied to
# PRs opened against each component (by component label).
# We target at least 75% of each component's PRs to be reviewed by a code owner,
# and each code owner to respond to at least 75% / n of their requested PRs (n = number of code owners for that component)
# (at least 3 code owners are required for components aiming for stable).
name: 'Generate Code Owner Activity Report'
on:
workflow_dispatch:
inputs:
dry_run:
description: 'Dry run (print report only, do not create issue)'
required: false
default: false
type: boolean
schedule:
# run on the 1st of every month at 2am UTC
- cron: "0 2 1 * *"
permissions:
contents: read
jobs:
report:
permissions:
contents: read
issues: write
pull-requests: read
runs-on: ubuntu-24.04
if: ${{ github.repository_owner == 'open-telemetry' }}
steps:
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
id: report
env:
DRY_RUN: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.dry_run == 'true' && 'true' || '0' }}
with:
retries: 3
script: |
const script = require('.github/workflows/scripts/generate-codeowners-activity.js')
await script({github, context})