Skip to content

Add local markdown linting to Makefile to avoid CI delays #4000

@Elia-Renzoni

Description

@Elia-Renzoni

Hi team,
I've been working on some documentation updates and noticed that markdown linting only happens in the CI pipeline.
This means every time there's a small formatting issue (like multiple blank lines), I have to push, wait for the entire test pipeline to run, see the error, fix it locally, and push again.
It would be really helpful to have a way to lint markdown files locally before pushing, similar to how we can run make lint for Go code. This would save a lot of time.
I was thinking of adding something like:

make lint-md - to check markdown files
make lint-md-fix - to auto-fix common formatting issues

Both would use the same markdownlint configuration that's already defined in .github/workflows/markdown_config.json.

Would this be acceptable? The only dependency would be having markdownlint-cli installed (via npm), but we could make it optional or add a check that fails gracefully if it's not installed.
If this sounds good, I'd be happy to submit a PR implementing it. Let me know what you think!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions