mirror of
https://github.com/vector-im/element-call.git
synced 2026-02-14 04:37:03 +00:00
See the description of pull_request versus pull_request_target documented at https://docs.github.com/en/actions/writing-workflows/choosing-when-your-workflow-runs/events-that-trigger-workflows#pull_request.
18 lines
482 B
YAML
18 lines
482 B
YAML
name: Prevent blocked
|
|
on:
|
|
pull_request_target:
|
|
types: [opened, labeled, unlabeled]
|
|
jobs:
|
|
prevent-blocked:
|
|
name: Prevent blocked
|
|
runs-on: ubuntu-latest
|
|
permissions:
|
|
pull-requests: read
|
|
steps:
|
|
- name: Add notice
|
|
uses: actions/github-script@v7
|
|
if: contains(github.event.pull_request.labels.*.name, 'X-Blocked')
|
|
with:
|
|
script: |
|
|
core.setFailed("PR has been labeled with X-Blocked; it cannot be merged.");
|