Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Feature Enhancement - MD005 - Inconsistent indentation for list items at the same level - Needs to list the indentation levels #520

Open
Labels
enhancementNew feature or request
@HariSekhon

Description

@HariSekhon

When getting hit with this on a markdown file, having a long list of lines to check is tedious, eg:

github-actions.md:44: MD005 Inconsistent indentation for list items at the same levelgithub-actions.md:46: MD005 Inconsistent indentation for list items at the same levelgithub-actions.md:47: MD005 Inconsistent indentation for list items at the same levelgithub-actions.md:49: MD005 Inconsistent indentation for list items at the same levelgithub-actions.md:50: MD005 Inconsistent indentation for list items at the same levelgithub-actions.md:51: MD005 Inconsistent indentation for list items at the same levelgithub-actions.md:369: MD005 Inconsistent indentation for list items at the same levelgithub-actions.md:373: MD005 Inconsistent indentation for list items at the same levelgithub-actions.md:382: MD005 Inconsistent indentation for list items at the same level

This results in having to check across hundreds of lines making it hard to find the culprit lines.

Requested Feature

Print the list indentation count of spaces of each line referenced in the output.

Workaround

I've just rustled up a couple Bash scripts to allow me to find the offending lists.

This script prefixed the indentation levels of the list lines reported by MDL:

https://github.com/HariSekhon/DevOps-Bash-tools/blob/master/markdown/mdl_list_indentations.sh

But they all showed a multiple of 2 indentations as expected, so I quickly wrote this:

https://github.com/HariSekhon/DevOps-Bash-tools/blob/master/markdown/markdown_list_indentations.sh

which shows the count of spaces on every list line, which showed that the lines causing this error weren't the ones listed bymdl but rather further up the page in the index section which was generated using another script:

https://github.com/HariSekhon/DevOps-Bash-tools/blob/master/markdown/markdown_generate_index.sh

which had been overridden to generate the index with 3 space indentation instead of 2 space indexation like the rest of the page was using.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp