Skip to content

Latest commit

 

History

History
101 lines (76 loc) · 1.96 KB

File metadata and controls

101 lines (76 loc) · 1.96 KB
id MDS058
name required-mentions
status ready
description Heading-bounded sections must contain every configured substring.
category prose
nature content
maintainability

MDS058: required-mentions

Heading-bounded sections must contain every configured substring.

The rule walks every heading in the document. For each heading the rule joins the plain text of paragraphs in the section's line range. The range runs from the heading down to the next heading at the same or shallower level, including nested sub-sections.

Each entry in mentions: is checked against the joined text. Missing mentions emit one diagnostic at the section's heading line. Under a schema scope override (plan 146), the per-scope filter keeps only diagnostics inside the scope's range.

Settings

Setting Type Default Description
mentions list [] Substrings that must each appear somewhere in the section's prose. Case-sensitive.

Config

Document-wide:

rules:
  required-mentions:
    mentions: ["scope: production"]

Per-section (via plan 146 schema scope):

kinds:
  runbook:
    schema:
      sections:
        - heading: "Rollback"
          rules:
            required-mentions:
              mentions: ["forward reference"]

Disable:

rules:
  required-mentions: false

Examples

Good

# Title

Deploy to production after the smoke test passes.

Bad

# Title

Deploy to staging.

Meta-Information

  • ID: MDS058
  • Name: required-mentions
  • Status: ready
  • Default: disabled
  • Fixable: no
  • Implementation: source
  • Category: prose