| id | MDS009 |
|---|---|
| name | single-trailing-newline |
| status | ready |
| description | File must end with exactly one newline character. |
File must end with exactly one newline character.
- ID: MDS009
- Name:
single-trailing-newline - Status: ready
- Default: enabled
- Fixable: yes
- Implementation: source
- Category: whitespace
Enable:
rules:
single-trailing-newline: trueDisable:
rules:
single-trailing-newline: false# Title
Content here.The file ends with exactly one \n after the last line.
# Title
Content here.The file has no trailing newline after the last line.
The <?include?> output looks identical because the
wrap always adds a newline, but the actual fixture file
(bad/default.md) ends without one — that missing byte
is what the rule detects.