Skip to content

Commit

Permalink
Remove mdformat in favor of pymarkdown
Browse files Browse the repository at this point in the history
mdformat has a known issue where it will escape brackets (to become
literals) when it encounters GitHub-Flavored Markdown extensions:
hukkin/mdformat#359 (comment)
It is also fairly agressive in ways that, on net, probably reduce
readability in ASCII form. Swap automation in favor of pymarkdown,
configured identically as in GoogleCloudPlatform/hpc-toolkit.
  • Loading branch information
tpdownes committed Feb 26, 2024
1 parent 87960d0 commit 917200f
Showing 1 changed file with 12 additions and 9 deletions.
21 changes: 12 additions & 9 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,19 @@ repos:
- id: end-of-file-fixer
- id: trailing-whitespace
- id: detect-private-key
- repo: https://github.com/executablebooks/mdformat
rev: 0.7.17
- repo: https://github.com/jackdewinter/pymarkdown
rev: v0.9.17
hooks:
- id: mdformat
args:
- --wrap=80
exclude: README_TF\.md
additional_dependencies:
- mdformat-toc
- mdformat-tables
- id: pymarkdown
# Rules at https://github.com/jackdewinter/pymarkdown/tree/main/docs/rules
# MD013 - Line length
# MD022 - Headers should be surrounded by blank lines
# MD033 - Inline HTML
# MD034 - Bare URL used
# MD041 - First line in file should be a top level header
# MD046 - Code block style
# MD024 - Multiple headings cannot contain the same content.
args: [--disable-rules, 'MD013,MD022,MD033,MD034,MD041,MD046,MD024', scan]
- repo: https://github.com/jumanjihouse/pre-commit-hook-yamlfmt
rev: 0.2.3
hooks:
Expand Down

0 comments on commit 917200f

Please sign in to comment.