docs: document brace alternation in glob patterns - #12281
Conversation
Brace alternation (`**/*.{js,ts}`) works in the engine as well as in
mergify-cli, and was documented nowhere.
Document it where the glob syntax reference actually lives, in
`configuration/data-types.mdx`, rather than in `conditions.mdx`, which
only links there. Cover the surprising parts: an empty branch is
dropped, an unbalanced brace is a configuration error rather than a
literal, and patterns are capped at 128 alternatives and 32 levels of
nesting.
Link the scopes pages to that reference, which they never did, and show
the brace form for `scopes.source.files`.
Fixes MRGFY-8393
Change-Id: I8a2c5abba0a84ed107f6e43a628c9eb0375ff68d
Merge Protections🔴 2 of 6 protections blocking · waiting on 👀 reviews
🔴 👀 Review RequirementsWaiting for
This rule is failing.
🔴 🔎 ReviewsWaiting for
This rule is failing.
Show 4 satisfied protections🟢 🤖 Continuous Integration
🟢 Enforce conventional commitMake sure that we follow https://www.conventionalcommits.org/en/v1.0.0/
🟢 📕 PR description
🟢 🚦 Auto-queueWhen all merge protections are satisfied, this pull request will be queued automatically. |
There was a problem hiding this comment.
🟢 Ready to approve
The changes are documentation-only, internally consistent, and links/anchors introduced in the diffs resolve to existing sections.
This review doesn't count toward merge requirements. Sign up for the private preview to control whether Copilot approvals count.
Pull request overview
This PR updates the docs to explicitly document brace alternation ({a,b}) as part of Mergify’s supported glob pattern syntax, and links merge-queue scope documentation back to the central glob syntax reference.
Changes:
- Expanded the glob pattern reference to include brace alternation behavior, limits, and YAML quoting/escaping caveats.
- Added a “Pattern Syntax” section to file-pattern scopes with an example using brace alternation and a note about invalid/unbalanced braces.
- Linked merge-queue scopes documentation directly to the glob syntax reference.
File summaries
| File | Description |
|---|---|
| src/content/docs/configuration/data-types.mdx | Adds brace alternation to the glob syntax reference, including examples, edge cases, and limits. |
| src/content/docs/merge-queue/scopes/file-patterns.mdx | Adds a scoped “Pattern Syntax” section linking to the glob/brace alternation reference and demonstrates {...} usage. |
| src/content/docs/merge-queue/scopes.mdx | Links include/exclude scope patterns to the canonical glob documentation. |
Review details
- Files reviewed: 3/3 changed files
- Comments generated: 0
- Review effort level: Lite
We're testing this review assessment. Please use 👍 or 👎 to tell us if it's correct.
Brace alternation (
**/*.{js,ts}) works in the engine as well as inmergify-cli, and was documented nowhere.
Document it where the glob syntax reference actually lives, in
configuration/data-types.mdx, rather than inconditions.mdx, whichonly links there. Cover the surprising parts: an empty branch is
dropped, an unbalanced brace is a configuration error rather than a
literal, and patterns are capped at 128 alternatives and 32 levels of
nesting.
Link the scopes pages to that reference, which they never did, and show
the brace form for
scopes.source.files.Fixes MRGFY-8393