Prevent merge if the custom labels are not present in Github

1.5k views Asked by At

I am setting up a hygiene development process for my team. As part of that, I want every code built to be unit tested and QA verified. I have created custom labels like QA Ready, Prod Ready for code repositories. How do I ensure that a PR is not merged to master unless the above custom labels are present?

1

There are 1 answers

0
Saurabh P Bhandari On

I think what you are looking for is : GitHub Actions

Run a workflow on any GitHub event

Kick off workflows with GitHub events like push, issue creation, or a new release. Combine and configure actions for the services you use, built and maintained by the community.

Whether you want to build a container, deploy a web service, or automate welcoming new users to your open source projects—there's an action for that. Pair GitHub Packages with Actions to simplify package management, including version updates, fast distribution with our global CDN, and dependency resolution, using your existing GITHUB_TOKEN.

You can explore existing GitHub Actions in the marketplace.

A quick search on the marketplace and I found this GitHub Action Enforce PR label.