Skip to content
vale-cliPublic

About

Markdown linters as Vale styles: markdownlint and rumdl

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

55 Commits

Folders and files

Repository files navigation

Markdown Build + Test Vale version license

Markdown linters as Vale styles: the rules each tool enforces, written as Vale rules and named as the tool names them.

These styles are for teams that already run Vale and want their markup rules in the same pass. If Markdown is all you lint, markdownlint and rumdl are the right tools, and every rule here is tested against their output.

Style Tool Rules, options, and differences
markdownlint markdownlint 0.42.2 (LICENSE) docs/markdownlint.md
rumdl rumdl 0.3.8 (LICENSE), the rules it has beyond markdownlint's docs/rumdl.md

Getting Started

Add the package to your configuration file and run vale sync, then name the styles you want:

StylesPath = styles
MinAlertLevel = suggestion

Packages = Markdown

[*.md]
BasedOnStyles = markdownlint, rumdl

Rules

A rule is named for the alias its tool gives it: MD010, no-hard-tabs, is markdownlint.NoHardTabs. Each tool's page lists its rules and says which are off until asked for.

Options

A rule is switched off, given a level, or set, as any Vale rule is:

markdownlint.NoInlineHtml = NO
markdownlint.LineLength = error
markdownlint.LineLength[max] = 100
markdownlint.UlStyle[prefer] = dash

OPTIONS.md has the setting for each option markdownlint has, 85 of its 91.

Fixes

A rule with a fix is applied with Vale's own command. It lints the page again after each pass, until nothing changes, and takes back a fix that leaves another rule something new to report:

$ vale fix --apply docs

Thirty-nine of the tools' rules are fixed, and each fix is held to the tool's own.

Development

$ cd script
$ npm install
$ cd ..
$ ./test.sh   # run each rule's cases, then compare them with markdownlint and rumdl

docs/development.md has the rest.

About

Markdown linters as Vale styles: markdownlint and rumdl

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages