[GH-ISSUE #1010] MD007 when MD010 disabled #2438

Open
opened 2026-03-07 20:07:46 +03:00 by kerem · 5 comments
Owner

Originally created by @Malix-Labs on GitHub (Oct 17, 2023).
Original GitHub issue: https://github.com/DavidAnson/markdownlint/issues/1010

Fix

Subject

MD007 when MD010 disabled

Object

When MD010 is disabled (hard tabs use case), it should be:

  • MD007.indent = 1 and MD007.start_indent = 1 by default
  • Formatting to tabs instead of spaces
Originally created by @Malix-Labs on GitHub (Oct 17, 2023). Original GitHub issue: https://github.com/DavidAnson/markdownlint/issues/1010 # Fix ## Subject MD007 when MD010 disabled ## Object When MD010 is disabled (hard tabs use case), it should be: - `MD007.indent = 1` and `MD007.start_indent = 1` by default - Formatting to tabs instead of spaces
Author
Owner

@DavidAnson commented on GitHub (Oct 17, 2023):

Just because tabs are allowed in a project does not mean they will/should be used for lists. Although I think that could be specified via a parameter to the rule.

<!-- gh-comment-id:1766942491 --> @DavidAnson commented on GitHub (Oct 17, 2023): Just because tabs are allowed in a project does not mean they will/should be used for lists. Although I think that could be specified via a parameter to the rule.
Author
Owner

@Malix-Labs commented on GitHub (Oct 17, 2023):

  • Comment Reply from @DavidAnson:

    because tabs are allowed in a project does not mean they will/should be used for lists

    Disagree
    It's a convention to normalize the indentation style project-wise
    If MD010 is disabled, it means that the project is enforcing a tab style indentation
    Tab style indentation => 1 tab / indentation

<!-- gh-comment-id:1766961636 --> @Malix-Labs commented on GitHub (Oct 17, 2023): - [Comment Reply](https://github.com/DavidAnson/markdownlint/issues/1010#issuecomment-1766942491) from @DavidAnson: > [⋯](https://github.com/DavidAnson/markdownlint/issues/1010#issuecomment-1766942491) because tabs are allowed in a project does not mean they will/should be used for lists [⋯](https://github.com/DavidAnson/markdownlint/issues/1010#issuecomment-1766942491) Disagree It's a convention to normalize the indentation style project-wise If MD010 is disabled, it means that the project is enforcing a tab style indentation Tab style indentation => 1 tab / indentation
Author
Owner

@DavidAnson commented on GitHub (Oct 17, 2023):

With very few exceptions, rules do not change their behavior based on how other rules are configured. This project prefers spaces and provides rule MD010 to help enforce that. Disabling MD010 does not introduce a requirement to use tabs. As the specification outlines, the behavior of tab stops is not always intuitive (https://spec.commonmark.org/0.30/#tabs).

It sounds like adding the parameter I propose above would satisfy your scenario.

<!-- gh-comment-id:1767014752 --> @DavidAnson commented on GitHub (Oct 17, 2023): With very few exceptions, rules do not change their behavior based on how other rules are configured. This project prefers spaces and provides rule MD010 to help enforce that. Disabling MD010 does not introduce a requirement to use tabs. As the specification outlines, the behavior of tab stops is not always intuitive (https://spec.commonmark.org/0.30/#tabs). It sounds like adding the parameter I propose above would satisfy your scenario.
Author
Owner

@Malix-Labs commented on GitHub (Oct 17, 2023):

  • Comment Reply from @DavidAnson:

    Disabling MD010 does not introduce a requirement to use tabs

    Do you mean that disabling MD010 does remove the requirement to not use hard tabs, rather that induce the requirement to use tabs?

  • Comment Reply from @DavidAnson:

    It sounds like adding the parameter I propose above would satisfy your scenario.

    If previous point is true, then agreed

<!-- gh-comment-id:1767033554 --> @Malix-Labs commented on GitHub (Oct 17, 2023): - [Comment Reply](https://github.com/DavidAnson/markdownlint/issues/1010#issuecomment-1767014752) from @DavidAnson: > [⋯](https://github.com/DavidAnson/markdownlint/issues/1010#issuecomment-1767014752) Disabling MD010 does not introduce a requirement to use tabs [⋯](https://github.com/DavidAnson/markdownlint/issues/1010#issuecomment-1767014752) Do you mean that disabling MD010 does remove the requirement to not use hard tabs, rather that induce the requirement to use tabs? - [Comment Reply](https://github.com/DavidAnson/markdownlint/issues/1010#issuecomment-1767014752) from @DavidAnson: > [⋯](https://github.com/DavidAnson/markdownlint/issues/1010#issuecomment-1767014752) It sounds like adding the parameter I propose above would satisfy your scenario. If previous point is true, then agreed
Author
Owner

@DavidAnson commented on GitHub (Oct 18, 2023):

Correct: MD010 will warn about tabs when it is enabled, but will do nothing when it is disabled.

<!-- gh-comment-id:1767410149 --> @DavidAnson commented on GitHub (Oct 18, 2023): Correct: MD010 will warn about tabs when it is enabled, but will do nothing when it is disabled.
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#2438
No description provided.