-
Notifications
You must be signed in to change notification settings - Fork 178
35 lines (29 loc) · 1006 Bytes
/
pr_labels.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
# Manages labels on PRs before allowing merging
name: PR labels
on:
pull_request:
types: [opened, labeled, unlabeled, synchronize]
# if a second commit is pushed quickly after the first, cancel the first one's build
concurrency:
group: pr-labels-${{github.head_ref}}
cancel-in-progress: true
jobs:
Labels:
runs-on: ubuntu-latest
permissions:
pull-requests: read # needed to utilize required-labels
steps:
- name: Merge-Blocking Labels # blocks merge if present
uses: mheap/github-action-required-labels@v3
with:
mode: exactly
count: 0
labels: "status: do not merge"
exit_type: failure
- name: Required Changelog Labels # require at least one of these labels
uses: mheap/github-action-required-labels@v3
with:
mode: minimum
count: 1
labels: "type: feature, type: bug, type: refactor, type: translation, ignore changelog"
exit_type: failure