Skip to content

Commit 4bc7d8f

Browse files
committed
add workflow for auto-labeling docs repo PRs
1 parent 67f51f1 commit 4bc7d8f

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed

auto-label-doc-repos.yml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
on:
2+
pull_request:
3+
types: [opened]
4+
5+
name: Auto-label new PRs
6+
7+
jobs:
8+
label:
9+
runs-on: ubuntu-latest
10+
steps:
11+
- uses: actions/github-script@v6
12+
with:
13+
github-token: ${{ secrets.DOCS_GH_PAT }}
14+
script: |
15+
const labels = ['type::feature', 'type::docs']
16+
github.rest.issues.addLabels({
17+
...context.repo,
18+
issue_number: context.issue.number,
19+
labels
20+
})

0 commit comments

Comments
 (0)