Skip to content

Commit 45d0766

Browse files
authored
docs: document new *= operator (#9259)
This adds documentation for the newly added "glob" operator. This operator was partly documented in the "data-types", so documenting the new "*=" operator in the conditions was the only thing required. Fixes MRGFY-6037
1 parent b1b35d0 commit 45d0766

File tree

2 files changed

+15
-1
lines changed

2 files changed

+15
-1
lines changed

src/content/docs/configuration/conditions.mdx

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -163,6 +163,19 @@ Here is a list of the available operators:
163163
true if any value matches.</td>
164164
</tr>
165165

166+
<tr>
167+
<td>Glob</td>
168+
169+
<td>
170+
`*=`
171+
</td>
172+
173+
<td>This operator checks for matching path using [Unix-style pathname
174+
pattern expansion](/configuration/data-types/#globs).
175+
If the target attribute type is a list, each element of the list is
176+
matched against the value and the condition is true if any value matches.</td>
177+
</tr>
178+
166179
<tr>
167180
<td>Greater Than or Equal</td>
168181

src/content/docs/configuration/data-types.mdx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,15 +44,16 @@ pull_request_rules:
4444
4545
You can use globs expressions with matching operators in your [conditions](/configuration/conditions).
4646
47+
{/* eslint-disable */}
4748
| Pattern | Description |
4849
|--------------------|-------------|
4950
| `**` (entire segment) | Matches any number of file or directory segments, including zero. |
5051
| `*` (entire segment) | Matches one file or directory segment. |
5152
| `*` (part of a segment) | Matches any number of non-separator characters, including zero. |
5253
| `?` | Matches one non-separator character. |
53-
{/* eslint-disable-next-line */}
5454
| `[seq]` | Matches one character in `seq`, where `seq` is a sequence of characters. Range expressions are supported; e.g., `[a-z]` matches any lowercase ASCII letter. Multiple ranges can be combined, e.g. `[a-zA-Z0-9_]` matches any ASCII letter, digit, or underscore. |
5555
| `[!seq]` | Matches one character **not** in `seq`, where `seq` follows the same rules as above. |
56+
{/* eslint-enable */}
5657

5758
:::note
5859
For a literal match, wrap the meta-characters in brackets. For example, `[?]` matches the character `?`.

0 commit comments

Comments
 (0)