Python Bytes

#426 Committing to Formatted Markdown

45 snips
Mar 31, 2025
Discover the magic of mdformat, an opinionated Markdown auto-formatter that enforces stylish consistency. Learn how to master Markdown lists and enhance your coding efficiency with tools like PipX and pre-commit hooks. Explore the latest Python Enhancement Proposals, including PEP 578 and 781, and dive into the realm of privacy-centered search engines. Enjoy a lighthearted discussion on Python dependency management, sprinkled with humorous anecdotes that make coding quirks relatable!
Ask episode
AI Snips
Chapters
Transcript
Episode notes
ADVICE

Format Markdown with mdformat

  • Use mdformat to automatically format your Markdown files.
  • Configure plugins to format code blocks within Markdown, supporting various languages like Python, JavaScript, and HTML.
INSIGHT

Numbered Lists in mdformat

  • mdformat converts numbered list items to all be "1." by default.
  • This reduces the number of Git diffs when reordering items, as only changed items are highlighted.
ADVICE

Consecutive Numbering with mdformat

  • If you find the "all ones" numbering less readable, use the --number flag.
  • This flag makes mdformat number lists consecutively, which is also helpful for reordering.
Get the Snipd Podcast app to discover more snips from this episode
Get the app