Enable markdown formatting with JuliaFormatter#4572
Conversation
Also fixes two markdown files with code blocks that would cause the formatter to error.
|
📖 Docs preview for this PR: https://clima.github.io/ClimaAtmos.jl/previews/PR4572/ |
|
@petebachant @ph-kev Do you have any thoughts on the conflict between trailing-whitespaces and JuliaFormatter? I went with JuliaFormatter here because its markdown formatting is more comprehensive. There is probably a way to configure JuliaFormatter to agree with trailing-whitespaces, but I'm not sure it is worth the effort |
|
I think the simplest thing to do is to use the Markdown formatting from JuliaFormatter. I don't have a strong preference using trailing-whitespaces versus JuliaFormatter for formatting the markdown files. |
|
I find the Markdown formatting a little weird, e.g., indenting list items, but what really matters is that whatever system is put in place prevents superfluous formatting changes from making it into PRs. Might want to add running |
TODO
check rendered docs
Content
The trailing whitespace remover used in the pre-commit hook is at odds with the JuliaFormatter's markdown style. I made the trailing whitespace hook ignore markdown files. They disagree on if empty lines should be empty or have four spaces