Skip to content

Commit 89f05bb

Browse files
authored
Merge PR #149: MDS036: add per-heading fixtures and correct plan 51 wording
2 parents 7958dcd + 79aa5bf commit 89f05bb

3 files changed

Lines changed: 36 additions & 1 deletion

File tree

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
---
2+
settings:
3+
max: 0
4+
per-heading:
5+
- pattern: "^Changelog$"
6+
max: 2
7+
diagnostics:
8+
- line: 3
9+
column: 1
10+
message: 'section "## Changelog" too long (5 > 2)'
11+
---
12+
# Overview
13+
14+
## Changelog
15+
16+
- entry one
17+
- entry two
18+
- entry three
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
---
2+
settings:
3+
max: 0
4+
per-heading:
5+
- pattern: "^Short$"
6+
max: 4
7+
---
8+
# Title
9+
10+
## Short
11+
12+
One line.
13+
14+
## Longer section with no matching pattern
15+
16+
This section is longer but stays untouched because only headings
17+
matching `^Short$` are capped and the default `max` is zero.

plan/51_section-level-size-limits.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ to prevent oversized headings from hiding in otherwise compliant files.
1414

1515
1. [x] Define section boundary detection rules for heading levels.
1616
2. [x] Add configuration for per-heading or per-pattern limits.
17-
3. [x] Implement rule to count section length by lines or tokens.
17+
3. [x] Implement rule to count section length by lines.
1818
4. [x] Document configuration and examples.
1919

2020
## Acceptance Criteria

0 commit comments

Comments
 (0)