{"ast":{"$$mdtype":"Tag","name":"article","attributes":{},"children":[{"$$mdtype":"Tag","name":"Heading","attributes":{"level":1,"id":"recheck","__idx":0},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["recheck"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"introduction","__idx":1},"children":["Introduction"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["recheck"]}," command lints Markdown files for structure and prose problems."," ","It checks headings, lists, links, tables, code fences, and whitespace, and the words themselves: banned terms, spelling, repeated words, heading case, sentence length, and readability."," ","With ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--fix"]},", it repairs the findings it can."," ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["recheck"]}," also lints the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["description"]}," fields of API descriptions."," ","Each finding reports the file, line, and column of the description in the source."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Rules come from presets such as ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["recheck/markdown"]}," that you add to the root ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["extends"]}," of ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["redocly.yaml"]},", and from the ",{"$$mdtype":"Tag","name":"Link","attributes":{"href":"/docs/cli/v2/configuration/reference/recheck"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["recheck"]}," block"]},", which adjusts preset rules and adds your own."," ","The ",{"$$mdtype":"Tag","name":"Link","attributes":{"href":"/docs/cli/v2/recheck"},"children":["Markdown and prose linting"]}," section explains the presets, the rules, and how to write a prose rule."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["How the command picks its rules:"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["With no ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["redocly.yaml"]},", it uses ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["recheck/markdown"]},"."]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["With a ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["redocly.yaml"]}," that has neither a Recheck preset in ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["extends"]}," nor a ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["recheck"]}," block, it checks nothing and says so."]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["It reads the root configuration only."," ","Recheck settings under ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["apis.<name>"]}," are not used, and the command warns about them."]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["With no paths, the command lints the Markdown files under the current directory and every local API in ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["apis"]},"."," ","It skips a remote API and says so."," ","With paths, a Markdown file or directory lints as pages, and an API description file lints its descriptions."," ","With an alias from ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["apis"]},", the command lints the descriptions of that API."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"usage","__idx":2},"children":["Usage"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"redocly recheck\nredocly recheck <paths>...\nredocly recheck <paths>... [--fix] [--rule=<name>] [--skip-rule=<name>] [--tags=<tag>]\nredocly recheck <paths>... [--format=<value>] [--max-problems=<n>] [--stats] [--summary=<value>]\nredocly recheck <paths>... --readability [--format=table|json]\nredocly recheck <paths>... --generate-baseline\nredocly recheck --generate-markdoc-schema --from=<path>... --output=<path> [--check]\nredocly recheck --help\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"Admonition","attributes":{"type":"info","name":"One action per run"},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--readability"]},", ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--generate-baseline"]},", and ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--generate-markdoc-schema"]}," each replace the default lint action."," ","Use at most one of them in a run."," ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--fix"]}," works with the default lint action only."]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"options","__idx":3},"children":["Options"]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Option"},"children":["Option"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Type"},"children":["Type"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Description"},"children":["Description"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["paths"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["[string]"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Files, folders, or aliases from ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["apis"]}," to lint. Default value is the current directory. See ",{"$$mdtype":"Tag","name":"Link","attributes":{"href":"#choose-files"},"children":["Choose files"]},"."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["--check"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["boolean"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Fail when the generated schema differs from the file in ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--output"]},". Use with ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--generate-markdoc-schema"]},"."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["--config"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Path to the ",{"$$mdtype":"Tag","name":"Link","attributes":{"href":"/docs/cli/v2/configuration"},"children":["configuration file"]},"."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["--fix"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["boolean"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Apply fixes to the Markdown files. Alias: ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["-f"]},". See ",{"$$mdtype":"Tag","name":"Link","attributes":{"href":"#fix-findings"},"children":["Fix findings"]},"."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["--format"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Format for the report.",{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Possible values:"]}," ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["table"]},", ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["json"]},", ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["sarif"]},", ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["github-actions"]},". Default value is ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["table"]},". See ",{"$$mdtype":"Tag","name":"Link","attributes":{"href":"#formats"},"children":["Formats"]},"."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["--from"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["[string]"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Module paths to read Markdoc tags from. Use with ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--generate-markdoc-schema"]},"."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["--generate-baseline"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["boolean"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Write a baseline file from the current errors. See ",{"$$mdtype":"Tag","name":"Link","attributes":{"href":"#use-a-baseline"},"children":["Use a baseline"]},"."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["--generate-markdoc-schema"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["boolean"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Generate a Markdoc tag schema from theme modules. Needs ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--from"]}," and ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--output"]},". See ",{"$$mdtype":"Tag","name":"Link","attributes":{"href":"#generate-a-markdoc-tag-schema"},"children":["Generate a Markdoc tag schema"]},"."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["--help"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["boolean"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Show help."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["--lint-config"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Specify the severity level for the configuration file.",{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]}," ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Possible values:"]}," ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["warn"]},", ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["error"]},", ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["off"]},". Default value is ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["warn"]},"."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["--max-problems"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["number"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Maximum number of problems in the report; applies to every format. See ",{"$$mdtype":"Tag","name":"Link","attributes":{"href":"#limit-the-report"},"children":["Limit the report"]},"."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["--output"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Output file for the generated schema. Use with ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--generate-markdoc-schema"]},"."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["--readability"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["boolean"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Report readability scores instead of lint findings. See ",{"$$mdtype":"Tag","name":"Link","attributes":{"href":"#check-readability"},"children":["Check readability"]},"."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["--rule"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["[string]"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Run only these rules. Alias: ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["-r"]},". See ",{"$$mdtype":"Tag","name":"Link","attributes":{"href":"#work-rule-by-rule"},"children":["Work rule by rule"]},"."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["--skip-rule"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["[string]"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Skip these rules."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["--stats"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["boolean"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Print the number of findings per rule after the table. Alias: ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["-s"]},"."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["--summary"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Print a summary of the run.",{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Possible values:"]}," ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["json"]},", ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["text"]},". See ",{"$$mdtype":"Tag","name":"Link","attributes":{"href":"#summarize-a-run"},"children":["Summarize a run"]},"."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["--summary-path"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Write the summary to this file instead of printing it."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["--tags"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["[string]"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Run only rules with these tags."]}]}]}]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Every option can also be set with an environment variable prefixed ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["REDOCLY_CLI_RECHECK_"]},", for example ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["REDOCLY_CLI_RECHECK_FORMAT=json"]},"."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"output-and-exit-codes","__idx":4},"children":["Output and exit codes"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The report goes to standard output, and progress messages go to standard error, so a ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["json"]}," or ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["sarif"]}," report can be piped to a file or another tool."]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Exit code"},"children":["Exit code"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Meaning"},"children":["Meaning"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["0"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["No errors. Warnings and info findings may be present."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["1"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["At least one error, a configuration error, a missing baseline, or a failed run."]}]}]}]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Only findings with severity ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["error"]}," fail the run."," ","See ",{"$$mdtype":"Tag","name":"Link","attributes":{"href":"/docs/cli/v2/recheck#severity-levels"},"children":["severity levels"]},"."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"examples","__idx":5},"children":["Examples"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"lint-a-folder","__idx":6},"children":["Lint a folder"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Add a preset to the root ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["extends"]},":"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"yaml","header":{"controls":{"copy":{}}},"source":"extends:\n  - recheck/markdown\n","lang":"yaml"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Then run the command on a folder:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"redocly recheck docs\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The command lints every Markdown file under ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["docs"]}," with the rules from ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["recheck/markdown"]}," and prints a table:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"text","header":{"controls":{"copy":{}}},"source":"📋 Found 3 issue(s):\n\nblanks-around-headings    docs/index.md:1:1    Headings should be surrounded by blank lines (Expected: 1; Actual: 0; Below) [fixable]\nblanks-around-headings    docs/index.md:2:1    Headings should be surrounded by blank lines (Expected: 1; Actual: 0; Above) [fixable]\nsingle-h1                 docs/index.md:2:1    Multiple top-level headings in the same document\n\n   2 of 3 fixable with --fix\n\n   3 error(s)\n","lang":"text"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Each row shows the rule name without its ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["recheck/"]}," prefix, the file with line and column, and the message."," ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["[fixable]"]}," marks the findings that ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--fix"]}," repairs."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"choose-files","__idx":7},"children":["Choose files"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Pass any number of files and folders."," ","A folder is searched for ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":[".md"]}," and ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":[".markdown"]}," files, and the search skips hidden folders, ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["node_modules"]},", ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["dist"]},", and ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["build"]},":"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"redocly recheck README.md docs guides/intro.md\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["For a path that is an API description, or an alias from ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["apis"]},", the command lints the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["description"]}," fields of that API."," ","When a file or folder exists with the same name as an alias, the command lints the file or folder."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"fix-findings","__idx":8},"children":["Fix findings"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"redocly recheck docs --fix\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The command writes the fixes to the files, lints them again until no more fixes apply, and lists every edit it made."," ","The report then shows only the findings that remain."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["A fix is withheld when it overlaps another fix or would rewrite a ",{"$$mdtype":"Tag","name":"Link","attributes":{"href":"/docs/cli/v2/recheck/markdoc"},"children":["Markdoc tag"]},"."," ","Withheld fixes are counted in the output, and their findings stay in the report."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Set ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["fix: false"]}," on a rule in the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["recheck"]}," block to keep that rule detection-only."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"turn-off-a-rule","__idx":9},"children":["Turn off a rule"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Set the rule to ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["off"]}," in the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["recheck"]}," block:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"yaml","header":{"controls":{"copy":{}}},"source":"extends:\n  - recheck/markdown\nrecheck:\n  rules:\n    recheck/line-length: off\n","lang":"yaml"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The run applies every rule from ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["recheck/markdown"]}," except ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["recheck/line-length"]},"."," ","The ",{"$$mdtype":"Tag","name":"Link","attributes":{"href":"/docs/cli/v2/recheck/presets#tune-a-preset"},"children":["Presets"]}," page shows how to change a severity or an option."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"work-rule-by-rule","__idx":10},"children":["Work rule by rule"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["A new rule on an existing document set can produce hundreds of findings."," ","Run one rule at a time to clear them:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"redocly recheck docs --rule=line-length\nredocly recheck docs --rule=line-length --fix\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--rule"]}," and ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--skip-rule"]}," accept the name the report prints or the full key, such as ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["recheck/line-length"]}," or ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["google/no-via"]},"."," ","Repeat the option for several rules."," ","A name that matches no rule in the configuration is an error, not an empty run, and the message lists the available rules."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--tags"]}," runs only the rules that carry one of the given tags."," ","The Markdown rules carry markdownlint's tags, such as ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["headings"]},", ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["links"]},", ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["whitespace"]},", ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["code"]},", and ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["accessibility"]},"."," ","Your own rules carry the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["tags"]}," you set on them."]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"redocly recheck docs --tags=headings --tags=links\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"formats","__idx":11},"children":["Formats"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":4,"id":"table","__idx":12},"children":["table"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The default, shown in ",{"$$mdtype":"Tag","name":"Link","attributes":{"href":"#lint-a-folder"},"children":["Lint a folder"]},"."," ","Add ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--stats"]}," to print the number of findings per rule after the table."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":4,"id":"json","__idx":13},"children":["json"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"redocly recheck docs --format=json > recheck.json\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The report has a ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["summary"]}," with the file count and a breakdown per rule, and an ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["issues"]}," list with one entry per finding:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"json","header":{"controls":{"copy":{}}},"source":"{\n  \"summary\": {\n    \"filesScanned\": 1,\n    \"totalIssues\": 1,\n    \"breakdown\": {\n      \"recheck/single-h1\": { \"errors\": 1, \"warnings\": 0, \"info\": 0, \"total\": 1 }\n    }\n  },\n  \"issues\": [\n    {\n      \"file\": \"docs/index.md\",\n      \"line\": 2,\n      \"column\": 1,\n      \"text\": \"# Second title\",\n      \"match\": \"Second title\",\n      \"ruleName\": \"recheck/single-h1\",\n      \"severity\": \"error\",\n      \"message\": \"Multiple top-level headings in the same document\",\n      \"fixable\": false\n    }\n  ]\n}\n","lang":"json"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":4,"id":"sarif","__idx":14},"children":["sarif"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"redocly recheck docs --format=sarif > recheck.sarif\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["A SARIF 2.1.0 report for code scanning tools, such as GitHub code scanning."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":4,"id":"github-actions","__idx":15},"children":["github-actions"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"redocly recheck docs --format=github-actions\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["In a GitHub Actions workflow, this format adds each finding as an annotation on the changed line."," ","An error becomes ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["::error"]},", a warning ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["::warning"]},", and an info finding ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["::notice"]},"."," ","Each finding is one line of output:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"text","header":{"controls":{"copy":{}}},"source":"::error title=recheck/single-h1,file=docs/index.md,line=2,endLine=2,col=1,endColumn=1::Multiple top-level headings in the same document\n","lang":"text"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["GitHub shows at most 10 error and 10 warning annotations per step, so pair this format with ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--max-problems"]},":"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"yaml","header":{"controls":{"copy":{}}},"source":"- name: Lint Markdown\n  run: npx @redocly/cli@latest recheck docs --format=github-actions --max-problems=20\n","lang":"yaml"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"limit-the-report","__idx":16},"children":["Limit the report"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"redocly recheck docs --max-problems=20\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The command sorts the findings by severity, then by file, line, and column, and reports the first 20."," ","The table's counts still cover every finding, and a note on standard error says how many were hidden."," ","Without the option, every finding is reported."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"summarize-a-run","__idx":17},"children":["Summarize a run"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"redocly recheck docs --summary=text\nredocly recheck docs --summary=json --summary-path=recheck-summary.json\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The summary counts the files scanned and the findings by severity and by rule."," ","It prints on standard error, or goes to the file in ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--summary-path"]},"."," ","Use it to decide the severity of each rule from the counts when you ",{"$$mdtype":"Tag","name":"Link","attributes":{"href":"/docs/cli/v2/recheck#adopt-recheck-on-an-existing-project"},"children":["adopt Recheck"]},"."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"use-a-baseline","__idx":18},"children":["Use a baseline"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["A baseline records the current errors."," ","Later runs report only errors that the baseline does not list."]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"redocly recheck docs --generate-baseline\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The command writes ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":[".redocly.recheck-baseline.yaml"]}," next to ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["redocly.yaml"]},"."," ","Commit the file."," ","Later runs pick it up automatically and print how many findings matched, how many are new, and how many baseline entries are stale."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["After you fix errors, generate the baseline again and commit the smaller file."," ","A stale baseline fails the run, so the file always equals reality."," ",{"$$mdtype":"Tag","name":"Link","attributes":{"href":"/docs/cli/v2/recheck/suppress-findings#use-a-baseline"},"children":["Use a baseline"]}," describes the file format and the rules of comparison."," ","When an API description does not parse, the command writes no baseline and fails."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"lint-api-descriptions","__idx":19},"children":["Lint API descriptions"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"redocly recheck openapi.yaml\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The command lints every ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["description"]}," in ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["openapi.yaml"]}," and in the files it references."," ","Rules that need a whole document, such as ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["recheck/single-h1"]},", do not run on descriptions."," ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--fix"]}," does not change API files."," ","It reports how many fixable findings it skipped."," ","An API description that does not parse is an error and fails the run."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["To suppress one finding without a change to the API file, list it in ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":[".redocly.lint-ignore.yaml"]}," by file, rule, and pointer:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"yaml","header":{"controls":{"copy":{}}},"source":"openapi.yaml:\n  recheck/line-length:\n    - '#/info/description'\n","lang":"yaml"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Key the rule by its full name, such as ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["recheck/line-length"]},", or by its short name."," ","A local API that references a remote ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["$ref"]}," makes the command fetch it, the same as ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["redocly lint"]},"."," ","The command lints only descriptions in local files."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["To adjust rules for descriptions only, set ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["apiDescriptions.rules"]}," in the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["recheck"]}," block."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"check-readability","__idx":20},"children":["Check readability"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"redocly recheck docs --readability\nredocly recheck docs --readability --format=json\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The command prints one row per Markdown file with its Flesch reading ease, Flesch-Kincaid grade, Automated Readability Index, word count, and sentence count, followed by the medians."," ","The score reads the prose only: headings, code, front matter, and Markdoc tags do not count."," ","A file with no prose shows no score."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["This action never fails the run."," ","To fail on a readability bound, add a rule with the ",{"$$mdtype":"Tag","name":"Link","attributes":{"href":"/docs/cli/v2/recheck/assertions#metric"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["metric"]}," assertion"]},", which reads the same prose and the same formulas."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"generate-a-markdoc-tag-schema","__idx":21},"children":["Generate a Markdoc tag schema"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"redocly recheck --generate-markdoc-schema --from=@theme/markdoc/schema.js --output=markdoc-tags.yaml\nredocly recheck --generate-markdoc-schema --from=@theme/markdoc/schema.js --output=markdoc-tags.yaml --check\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The first command reads the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["tags"]}," export of a theme module and writes a tags file that ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["recheck.markdoc.extend.tagsFile"]}," can load."," ","The second compares the file with a fresh generation and fails if it differs, for CI."," ","See ",{"$$mdtype":"Tag","name":"Link","attributes":{"href":"/docs/cli/v2/recheck/markdoc#generate-a-tags-file-from-a-theme"},"children":["Markdoc tags"]}," for the details."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"use-a-custom-configuration-file","__idx":22},"children":["Use a custom configuration file"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"redocly recheck docs --config=./config/redocly.yaml\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The baseline file is looked up next to the configuration file that is used."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"resources","__idx":23},"children":["Resources"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"Link","attributes":{"href":"/docs/cli/v2/recheck"},"children":["Markdown and prose linting"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"Link","attributes":{"href":"/docs/cli/v2/configuration/reference/recheck"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["recheck"]}," configuration reference"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"Link","attributes":{"href":"/docs/cli/v2/recheck/presets"},"children":["Presets"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"Link","attributes":{"href":"/docs/cli/v2/recheck/rules"},"children":["Markdown rules"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"Link","attributes":{"href":"/docs/cli/v2/recheck/assertions"},"children":["Prose rules"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"Link","attributes":{"href":"/docs/cli/v2/recheck/suppress-findings"},"children":["Suppress findings"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"Link","attributes":{"href":"/docs/cli/v2/guides/migrate-from-markdownlint"},"children":["Migrate from markdownlint and Vale"]}]}]}]},"frontmatter":{},"tagList":["admonition","html"],"title":"recheck","lastModified":"2026-10-07T06:18:11.000Z"}