v0.1.0
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, andwrap, plus--max-widthsecondary 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-quotesand--ellipses, applied to prose only — never inside code, links, HTML tags, or skipped blocks. - CLI: in-place formatting of files and directory trees,
--check/--difffor CI,.mdreflow.yamlconfig with gitignore-syntax excludes,.gitignoreawareness, 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/FormatReaderandOptionsmay still change before v1.0.0.