Skip to content

v0.1.0

Choose a tag to compare

@github-actions github-actions released this 08 Aug 14:42
· 118 commits to main since this release
b7ed136

Note

Superseded by v0.1.1: identical code rebuilt with go1.25.8 to clear GO-2026-4602. Prefer v0.1.1.

First release. mdreflow reflows Markdown prose — sentence-per-line (semantic line breaks) by default, with paragraph-per-line and classic hard wrap on the same pipeline — and touches nothing else: no heading, list, table, or escaping changes, and everything outside reflowed prose passes through byte-for-byte.
It ships as a Go library (github.com/jbeda/mdreflow) with a thin CLI, is safe to run unattended (idempotent, render-preserving, loud refusals with a stable exit-code contract), and handles GFM, MDX/Docusaurus, and Hugo content by skipping dialect constructs rather than parsing them.

Added

  • Three modes: sentence (default), para, and wrap, plus --max-width secondary clause breaks in sentence mode.
  • Dialect skip-list: code blocks, front matter (YAML and TOML), tables, raw HTML, JSX blocks, ::: directives, math blocks, Hugo shortcodes, GitHub alerts, link reference definitions.
  • List and blockquote reflow with correct continuation prefixes (up to two nesting levels; deeper passes through untouched).
  • Hard-break preservation with style normalization (<br> default, spaces, backslash) and opt-in --strip-sentence-terminal-breaks.
  • Opt-in typography: --smart-quotes and --ellipses, applied to prose only — never inside code, links, HTML tags, or skipped blocks.
  • CLI: in-place formatting of files and directory trees, --check/--diff for CI, .mdreflow.yaml config with gitignore-syntax excludes, .gitignore awareness, non-Markdown refusal, and a fully self-documenting --help (exit codes 0 clean / 1 would-reformat / 2 usage or config error / 3 refused).
  • pre-commit hooks (mdreflow, mdreflow-check) and released binaries for linux, macOS, and Windows (amd64/arm64).

Notes

  • Known edge cases are tracked as issues #1–#8; none affect default sentence mode in normal use.
  • The library API is v0: Format/Check/FormatReader and Options may still change before v1.0.0.