[GH-ISSUE #505] .markdownlintignore use causing error #2260

Closed
opened 2026-03-07 20:06:05 +03:00 by kerem · 2 comments
Owner

Originally created by @jonesy1234 on GitHub (Mar 2, 2022).
Original GitHub issue: https://github.com/DavidAnson/markdownlint/issues/505

I have a pretty simple thing I'm trying to get working with using .markdownlint.json for configuration settings and .markdownlintignore files. All I want to do is get markdownlint to ignore CHANGELOG.md as we autogenerate the contents there for each release which flags MD025/single-title/single-h1 Multiple top-level headings in the same document

$ cat .markdownlint.json 
{
  "default": true,
  "MD013": false,
  "MD033": false
}

$ cat .markdownlintignore 
CHANGELOG.md

$ markdownlint -V
0.31.1

The command line just prompts the help output so doesn't like something but I can't work out what??

$ markdownlint  CHANGELOG.md
Usage: markdownlint [options] <files|directories|globs>

MarkdownLint Command Line Interface

Options:
  -V, --version                               output the version number
  -c, --config [configFile]                   configuration file (JSON, JSONC, JS, or YAML)
  -d, --dot                                   include files/folders with a dot (for example `.github`)
  -f, --fix                                   fix basic errors (does not work with STDIN)
  -i, --ignore [file|directory|glob]          file(s) to ignore/exclude (default: [])
  -j, --json                                  write issues in json format
  -o, --output [outputFile]                   write issues to file (no console)
  -p, --ignore-path [file]                    path to file with ignore pattern(s)
  -q, --quiet                                 do not write issues to STDOUT
  -r, --rules  [file|directory|glob|package]  include custom rule files (default: [])
  -s, --stdin                                 read from STDIN (does not work with files)
  --enable [rules...]                         Enable certain rules, e.g. --enable MD013 MD041
  --disable [rules...]                        Disable certain rules, e.g. --disable MD013 MD041
  -h, --help                                  display help for command

Are there any debug flags that I can apply to workout what is wrong? Thanks!

Originally created by @jonesy1234 on GitHub (Mar 2, 2022). Original GitHub issue: https://github.com/DavidAnson/markdownlint/issues/505 I have a pretty simple thing I'm trying to get working with using .markdownlint.json for configuration settings and .markdownlintignore files. All I want to do is get markdownlint to ignore CHANGELOG.md as we autogenerate the contents there for each release which flags ```MD025/single-title/single-h1 Multiple top-level headings in the same document``` ``` $ cat .markdownlint.json { "default": true, "MD013": false, "MD033": false } $ cat .markdownlintignore CHANGELOG.md $ markdownlint -V 0.31.1 ``` The command line just prompts the help output so doesn't like something but I can't work out what?? ``` $ markdownlint CHANGELOG.md Usage: markdownlint [options] <files|directories|globs> MarkdownLint Command Line Interface Options: -V, --version output the version number -c, --config [configFile] configuration file (JSON, JSONC, JS, or YAML) -d, --dot include files/folders with a dot (for example `.github`) -f, --fix fix basic errors (does not work with STDIN) -i, --ignore [file|directory|glob] file(s) to ignore/exclude (default: []) -j, --json write issues in json format -o, --output [outputFile] write issues to file (no console) -p, --ignore-path [file] path to file with ignore pattern(s) -q, --quiet do not write issues to STDOUT -r, --rules [file|directory|glob|package] include custom rule files (default: []) -s, --stdin read from STDIN (does not work with files) --enable [rules...] Enable certain rules, e.g. --enable MD013 MD041 --disable [rules...] Disable certain rules, e.g. --disable MD013 MD041 -h, --help display help for command ``` Are there any debug flags that I can apply to workout what is wrong? Thanks!
kerem 2026-03-07 20:06:05 +03:00
  • closed this issue
  • added the
    question
    label
Author
Owner

@DavidAnson commented on GitHub (Mar 2, 2022):

This is an issue for: https://github.com/igorshubovych/markdownlint-cli

That program will display its help text if there are no files to process. In your example, you are passing it just one file to process and also passing that file in the ignore list, so there is nothing left to do and so it displays the help text.

<!-- gh-comment-id:1056074395 --> @DavidAnson commented on GitHub (Mar 2, 2022): This is an issue for: https://github.com/igorshubovych/markdownlint-cli That program will display its help text if there are no files to process. In your example, you are passing it just one file to process and also passing that file in the ignore list, so there is nothing left to do and so it displays the help text.
Author
Owner

@jonesy1234 commented on GitHub (Mar 6, 2022):

ah cool, that makes sense. It threw me off a little as I'd assume I was facing a syntax error. Thanks

<!-- gh-comment-id:1060065737 --> @jonesy1234 commented on GitHub (Mar 6, 2022): ah cool, that makes sense. It threw me off a little as I'd assume I was facing a syntax error. Thanks
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/markdownlint#2260
No description provided.