Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 698fcd5

Browse files
story645QuLogic
andcommitted
prevent merge on label [skip circle] [skip azp] [skip appveyor]
Co-authored-by: Elliott Sales de Andrade <[email protected]>
1 parent ff0497c commit 698fcd5

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed

.github/workflows/do_not_merge.yml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
---
2+
name: Do Not Merge
3+
4+
# action to block merging on specific labels
5+
on:
6+
pull_request:
7+
types: [synchronize, opened, reopened, labeled, unlabeled]
8+
9+
permissions:
10+
checks: write
11+
12+
jobs:
13+
do-not-merge:
14+
if: >-
15+
contains(github.event.pull_request.labels.*.name, 'status: needs comment/discussion') ||
16+
contains(github.event.pull_request.labels.*.name, 'status: waiting for other PR')
17+
name: Prevent Merging
18+
runs-on: ubuntu-latest
19+
steps:
20+
- name: Check for label
21+
run: |
22+
echo "Following labels must be removed to allow merging: "
23+
echo "${{ toJson(github.event.pull_request.labels.*.name) }}"
24+
exit 1

0 commit comments

Comments
 (0)