Fork of github.com/shurcooL/markdownfmt that targets following additions:
- Goldmark used instead of Blackfriday to render from parsed markdown AST.
- Full info string support for Fenced Code Block (see issue).
- Hash-based headers only.
- Full Github Flavored Markdown support.
Like gofmt
, but for Markdown.
Note that markdownfmt
works with pure Markdown files. If you want to use it with Markdown files that have front matter, consider one of alternatives that supports that.
go get -u github.com/Kunde21/markdownfmt
Add $GOPATH/bin
to your $PATH
or copy $GOPATH/bin/markdownfmt
to your $PATH
.
usage: markdownfmt [flags] [path ...]
-d=false: display diffs instead of rewriting files
-l=false: list files whose formatting differs from markdownfmt's
-w=false: write result to (source) file instead of stdout
- vim-markdownfmt for Vim.
- emacs-markdownfmt for Emacs.
- Built-in in Conception.
- markdown-format for Atom (deprecated).
- Add a plugin for your favorite editor here?
mdfmt
- Fork ofmarkdownfmt
that adds front matter support.tidy-markdown
- Project with similar goals, but written in JS and based on a slightly different styleguide.