Platform Notes
- Optional helper plugins may help in some environments, but they must not be treated as required for this skill.
Markdown Lint Cleanup
Acknowledgement: Shared by Peter Bamuhigire, techguypeter.com, +256 784 464178.
Use When
- Fix markdown lint warnings by enforcing headings, blank lines around lists, and language-tagged code fences for clean documentation.
Evidence Produced
| Category |
Artifact |
Format |
Example |
| Correctness |
Markdown lint cleanup record |
Markdown doc tracking lint warnings fixed (headings, blank lines around lists, language-tagged fences) per pass |
docs/lint/markdown-cleanup-2026-04-16.md |
References
- Use the links and companion skills already referenced in this file when deeper context is needed.
Overview
Use this skill to clean markdown files so they pass lint checks with zero warnings. It focuses on consistent headings, spacing, and fenced code block language tags.
When to Use
- Markdown lint warnings appear (MD022, MD032, MD036, MD040, MD031)
- Documentation updates need a clean lint pass
- Large docs need formatting normalization without content changes
Core Rules (Required)
- Headings must be proper headings
- Replace bold-only headings with
##, ###, etc.
- Blank lines around lists
- Add a blank line before and after lists
- Blank lines around fenced code blocks
- Surround code fences with blank lines
- Language tags on fenced code blocks
- Use
bash, php, sql, or text as appropriate
Common Fixes
MD036: Emphasis used instead of a heading
Replace:
Section Title
With:
Section Title
MD032: Blanks around lists
Ensure blank lines before and after lists:
Text paragraph.
Next paragraph.
MD022: Blanks around headings
Add a blank line before and after headings:
Paragraph text.
Heading
MD040: Fenced code language
Add a language identifier:
Example output line
MD031: Blanks around fences
Ensure fences are separated from other text:
Paragraph text.
php scripts/verify_uom_system.php
File Safety
- Do not change meaning or content structure
- Only adjust formatting to satisfy lint rules
- Preserve links and references exactly
Recommended Workflow
- Identify lint warnings and their line numbers
- Apply targeted fixes (headings, spacing, code fence languages)
- Re-check lint until clean
Output Expectations
- No markdown lint warnings
- No content meaning changes
- Consistent formatting across documents
Decision Rules
| Condition |
Action |
| Fix is mechanical and meaning-preserving |
Apply narrowly |
| Rule conflicts with repository style |
Follow repository configuration |
| Fix alters meaning |
Stop and report separately |
Capability Contract
Read and search are required. Editing and lint execution require authorisation.
Degraded Mode
Fallback: without execution, return the patch and name the lint command still required.
Domain Anti-Patterns
- Rewording prose during formatting cleanup.
- Renumbering headings without checking links.
- Guessing a code-fence language.
- Formatting vendored files unintentionally.
- Claiming a clean run without evidence.
Inputs
| Artefact |
Required? |
Purpose |
| Markdown scope, lint rules, repository conventions, and protected content |
yes |
Bound safe cleanup |
Outputs
- Produce cleaned Markdown, lint results, and a note of intentionally retained exceptions.
1---2name: markdown-lint-cleanup3description: Use when fixing Markdown lint failures, heading structure, list spacing, code-fence languages, or local formatting consistency without changing document meaning.4metadata:5 portable: true6 compatible_with:7 - claude-code8 - codex9---1011## Platform Notes1213- Optional helper plugins may help in some environments, but they must not be treated as required for this skill.1415# Markdown Lint Cleanup16Acknowledgement: Shared by Peter Bamuhigire, techguypeter.com, +256 784 464178.1718<!-- dual-compat-start -->19## Use When2021- Fix markdown lint warnings by enforcing headings, blank lines around lists, and language-tagged code fences for clean documentation.2223## Evidence Produced2425| Category | Artifact | Format | Example |26|----------|----------|--------|---------|27| Correctness | Markdown lint cleanup record | Markdown doc tracking lint warnings fixed (headings, blank lines around lists, language-tagged fences) per pass | `docs/lint/markdown-cleanup-2026-04-16.md` |2829## References3031- Use the links and companion skills already referenced in this file when deeper context is needed.32<!-- dual-compat-end -->33## Overview3435Use this skill to clean markdown files so they pass lint checks with zero warnings. It focuses on consistent headings, spacing, and fenced code block language tags.3637## When to Use3839- Markdown lint warnings appear (MD022, MD032, MD036, MD040, MD031)40- Documentation updates need a clean lint pass41- Large docs need formatting normalization without content changes4243## Core Rules (Required)44451. **Headings must be proper headings**46 - Replace bold-only headings with `##`, `###`, etc.472. **Blank lines around lists**48 - Add a blank line before and after lists493. **Blank lines around fenced code blocks**50 - Surround code fences with blank lines514. **Language tags on fenced code blocks**52 - Use `bash`, `php`, `sql`, or `text` as appropriate5354## Common Fixes5556### MD036: Emphasis used instead of a heading5758**Replace**:5960**Section Title**6162**With**:6364## Section Title6566### MD032: Blanks around lists6768Ensure blank lines before and after lists:6970Text paragraph.7172- Item one73- Item two7475Next paragraph.7677### MD022: Blanks around headings7879Add a blank line before and after headings:8081Paragraph text.8283#### Heading8485- List item8687### MD040: Fenced code language8889Add a language identifier:9091```text92Example output line93```9495### MD031: Blanks around fences9697Ensure fences are separated from other text:9899Paragraph text.100101```bash102php scripts/verify_uom_system.php103```104105## File Safety106107- Do not change meaning or content structure108- Only adjust formatting to satisfy lint rules109- Preserve links and references exactly110111## Recommended Workflow1121131. Identify lint warnings and their line numbers1142. Apply targeted fixes (headings, spacing, code fence languages)1153. Re-check lint until clean116117## Output Expectations118119- No markdown lint warnings120- No content meaning changes121- Consistent formatting across documents122123## Decision Rules124125| Condition | Action |126|---|---|127| Fix is mechanical and meaning-preserving | Apply narrowly |128| Rule conflicts with repository style | Follow repository configuration |129| Fix alters meaning | Stop and report separately |130131## Capability Contract132133Read and search are required. Editing and lint execution require authorisation.134135## Degraded Mode136137Fallback: without execution, return the patch and name the lint command still required.138139## Domain Anti-Patterns140141- Rewording prose during formatting cleanup.142- Renumbering headings without checking links.143- Guessing a code-fence language.144- Formatting vendored files unintentionally.145- Claiming a clean run without evidence.146## Inputs147| Artefact | Required? | Purpose |148|---|---|---|149| Markdown scope, lint rules, repository conventions, and protected content | yes | Bound safe cleanup |150## Outputs151- Produce cleaned Markdown, lint results, and a note of intentionally retained exceptions.