mergify-merge-protections

Control GitHub PR merge timing and dependencies with Mergify protection rules.

64|2|Updated Nov 8, 2021
One-click install
npx skills add https://github.com/FlatbreadLabs/flatbread --skill mergify-merge-protections
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: mergify-merge-protections
Source: https://github.com/FlatbreadLabs/flatbread/tree/main/.agents/skills/mergify-merge-protections
Command: npx skills add https://github.com/FlatbreadLabs/flatbread --skill mergify-merge-protections

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Uncoordinated pull request merges can cause cross-repo dependency conflicts, break coordinated releases, or merge code during maintenance windows or production incidents, leading to downtime or broken features.

Core Features & Use Cases

  • PR Dependency Management: Use Depends-On headers to block a PR from merging until required dependent PRs (same-repo or cross-repo) are merged first, ideal for multi-repo feature launches or schema migration workflows.
  • Time-Delayed Merges: Use Merge-After headers to schedule PRs to merge at a specific date and time, perfect for coordinated releases or embargoed changes.
  • Scheduled Merge Freezes: Create repository-wide or conditional freezes to halt all merges during deployment windows, incident response, or code freeze periods, with support for exclusions like hotfix labels.

Quick Start

Use this skill to add a Depends-On header to your PR to block it from merging until its dependent PRs land, add a Merge-After header to schedule a delayed merge, or create a scheduled freeze to halt all merges during a maintenance window.

Frequently Asked Questions about mergify-merge-protections

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I block a GitHub pull request from merging until another PR is merged?

You can block a GitHub pull request from merging until dependent PRs land by adding a Depends-On header to the PR body, which enforces cross-repo or same-repo dependency rules. This coordinates multi-repo feature launches or schema migrations.

Can I schedule a GitHub pull request to merge at a specific date and time?

Yes, you can schedule a GitHub pull request to merge at a specific date and time by adding a Merge-After header to the PR body. This is useful for coordinating embargoed releases or timed feature launches.

What is a scheduled merge freeze and when do I need it?

A scheduled merge freeze is a repository-wide or conditional halt on all pull request merges. You need it during deployment windows, incident response, or code freeze periods to prevent breaking changes from merging into production.

Does Mergify support merge freeze exclusions for hotfixes?

Yes, Mergify supports merge freeze exclusions for hotfixes using conditional matching and exclusion rules. You can apply labels like hotfix to allow specific pull requests to bypass the freeze and merge during incidents.

How do I coordinate cross-repo pull request merges with dependencies?

You coordinate cross-repo pull request merges by using Depends-On headers in the PR body to specify required dependent PRs across repositories. This blocks merging until all required changes land successfully.

What's the best way to halt all PR merges during an incident response?

The best way to halt all PR merges during an incident response is to create a scheduled merge freeze with conditional matching rules. This stops all pull requests from merging while allowing hotfix exclusions if needed.