Skip to content

Do not require valid labels if they are not specified #29

Open
@pmalek-sumo

Description

@pmalek-sumo

Hello,

Thanks for this awesome plugin!

I have a use case that involves only checking if a particular "invalid plugin" is set, let's say do not merge. I don't want to specify "positive labels" or in other words: I don't want to be forced to mark PRs as checked/ready to reviews/or else.

The only constraint I want this plugin to do is to add a "Request changes" review when do not merge label is added.

Can we somehow achieve this with current version of this PR or maybe it would require some changes to its core logic?

Here's the comment that this plugin outputs (ref)

This pull request does not contain a valid label. Please add one of the following labels: ['']

When the following config is used:

name: PRs Labels

on:
  pull_request_target:
    types: [opened, labeled, unlabeled, synchronize]

jobs:
  label:
    runs-on: ubuntu-latest
    steps:
      - uses: jesusvasquez333/verify-pr-label-action@v1.4.0
        with:
          github-token: '${{ secrets.GITHUB_TOKEN }}'
          invalid-labels: 'do not merge'
          pull-request-number: '${{ github.event.pull_request.number }}'

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions