Skip to content

ci: Add workflow to prevent merging PRs with 'dont-merge' label #2

ci: Add workflow to prevent merging PRs with 'dont-merge' label

ci: Add workflow to prevent merging PRs with 'dont-merge' label #2

Workflow file for this run

name: Mergeability
on:
pull_request:
types: [opened, reopened, labeled, unlabeled]
env:
DO_NOT_MERGE_LABEL: 'dont-merge'
jobs:
check-labels:
runs-on: ubuntu-latest
name: Allow merging
if: ${{ contains(github.event.*.labels.*.name, ${{ env.DO_NOT_MERGE_LABEL }}) }}

Check failure on line 14 in .github/workflows/mergeability.yml

View workflow run for this annotation

GitHub Actions / Mergeability

Invalid workflow file

The workflow is not valid. .github/workflows/mergeability.yml (Line: 14, Col: 9): Unexpected symbol: '${{'. Located at position 40 within expression: contains(github.event.*.labels.*.name, ${{ env.DO_NOT_MERGE_LABEL
steps:
- name: Fail test due to '${{ env.DO_NOT_MERGE_LABEL }}' label presence
run: exit 1