Skip to content

document-end

What this rule does

Requires or forbids the YAML document end marker (...).

Why this matters

  • Streaming consumers. Producers that emit multiple YAML documents benefit from explicit end markers so consumers know each document is complete.
  • Single-document files. Most single-document YAML files omit ...; forbidding it removes a trailing footer that adds no information.

Configuration

[rules.document-end]
level = "error"
present = true
Option Default Description
present true When true, require a ... marker at the end of every document. When false, forbid it.

Examples

✅ Allowed (with present: true)

---
this: is the only document
...

❌ Reported (with present: true)

---
this: is the only document

✅ Allowed (with present: false)

---
this: is the only document

Automatic fixing

This rule does not auto-fix; add or remove the marker manually.