Markdown linter written in python. Inspired by mivok/markdownlint.
Get started by running:
markdownlint examples/ # lint all files in a directory
markdownlint examples/example1.md # lint a single file
markdownlint examples/example1.md # lint a single file
NOTE: The returned exit code equals the number of errors found.
Other commands and variations:
Usage: markdownlint [OPTIONS] PATH
Markdown lint tool, checks your markdown for styling issues
Options:
--config PATH Config file location (default: .markdownlint).
--list-files List markdown files in given path and exit.
--ignore TEXT Ignore rules (comma-separated by id or name).
--version Show the version and exit.
--help Show this message and exit.
You can modify pymarkdownlint's behavior by specifying a config file like so:
markdownlint --config myconfigfile
By default, markdownlint will look for an optional .markdownlint
file for configuration.
[general]
# rules can be ignored by name or by id
ignore=max-line-length,MD013
Please see the ruleset here.
Installation:
# Use pipenv for development
pip install pipenv
pipenv install --dev
pipenv shell
To run tests:
pipenv shell # If you have yet to run this
pytest
- More rules!
- Better output handling with verbosity levels
- Ignore/exclude files CLI options
- Rule specific configuration in config files
- Auto doc generation based on rules