Skip to content

Enable markdown formatting with JuliaFormatter#4572

Open
imreddyTeja wants to merge 3 commits into
mainfrom
tr/fmt
Open

Enable markdown formatting with JuliaFormatter#4572
imreddyTeja wants to merge 3 commits into
mainfrom
tr/fmt

Conversation

@imreddyTeja

@imreddyTeja imreddyTeja commented Jun 10, 2026

Copy link
Copy Markdown
Member

TODO

check rendered docs

Content

  • also fixes two code blocks that cause the parser to error
  • adds ignores files in .github and dev-docs

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


  • I have read and checked the items on the review checklist.

@imreddyTeja imreddyTeja changed the title Tr/fmt Enable markdown formatting with JuliaFormatter Jun 10, 2026
@imreddyTeja imreddyTeja marked this pull request as ready for review June 10, 2026 19:59
@github-actions

Copy link
Copy Markdown
Contributor

📖 Docs preview for this PR: https://clima.github.io/ClimaAtmos.jl/previews/PR4572/

@imreddyTeja

Copy link
Copy Markdown
Member Author

@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

@ph-kev

ph-kev commented Jun 10, 2026

Copy link
Copy Markdown
Member

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.

@petebachant

Copy link
Copy Markdown
Member

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 prek to the formatter Actions workflow so we're not depending on devs to format on their own.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants