mcpField
M
markdownlint

markdownlint

github.com/perdoliqueTesting & quality051 installsUpdated 1d ago
Repository

About markdownlint

A markdownlint skill for configuring, running, and troubleshooting Markdown linting in projects. It guides package-manager detection, rule selection, exclusions, fixes, and integration.

Key features

  1. 01Detects the project's package manager
  2. 02Guides setup and configuration
  3. 03Explains rules and ignored files
  4. 04Covers fixes and integrations

Use cases

  1. 01Set up markdownlint in a project
  2. 02Choose or adjust lint rules
  3. 03Exclude generated Markdown files
  4. 04Diagnose linting or hook issues

Install

Copy the command and run it in a terminal.

$npx skills add https://github.com/perdolique/workflow --skill markdownlint

After installing, type/markdownlintin Claude Code to confirm it loaded.

Bundled files

References and scripts installed along with SKILL.md.

references/
fixing.md
ignoring.md
integration.md
rules.md
setup.md
troubleshooting.md

Details

From the project README

Markdownlint

Package manager detection

Before any operation, detect which package manager the project uses:

  1. Check for lock files:

    • pnpm-lock.yaml → use pnpm
    • yarn.lock → use yarn
    • package-lock.json → use npm
    • bun.lockb → use bun
  2. Check packageManager field in package.json:

    "packageManager": "[email protected]"
    
  3. If no indicators, ask the user which package manager they prefer

Throughout this skill, commands use pnpm as examples. Replace with the detected package manager:

  • pnpm add -D → npm install --save-dev / yarn add -D / bun add -d
  • pnpm run → npm run / yarn run / bun run
  • pnpm install → npm install / yarn install / bun install

Operation selection guide

Read the reference matching the requested work:

OperationReference
Installation, configuration files, scripts, and verification instructionsSetup
Rule names, codes, options, enabling, or disabling rulesRules
Ignored files, folders, patterns, and checking exclusionsIgnoring
Diagnosing violations, automatic fixes, and remaining manual fixesFixing
Scripts, hooks, CI, and editor integrationIntegration
Missing files, failed hooks, installation errors, or performance problemsTroubleshooting

For a request spanning several operations, read the main reference first, then the related references needed to complete and verify the setup.

Quick reference: Common commands

# Install
pnpm add -D markdownlint markdownlint-cli

# Run linting
pnpm run lint:markdown

# Auto-fix issues
vpx markdownlint '**/*.md' --fix

# Lint specific file
vpx markdownlint README.md

# Lint specific directory
vpx markdownlint 'docs/**/*.md'

Quick reference: Config file basics

.markdownlint.yaml in project root:

$schema: ./node_modules/markdownlint/schema/markdownlint-config-schema.json

# Disable a rule
line-length: false

# Enable a rule
no-duplicate-heading: true

# Configure a rule
heading-style:
  style: "atx"

.markdownlintignore in project root (gitignore syntax):

node_modules
dist/
build/
CHANGELOG.md

Default configuration philosophy

When setting up markdownlint, use this opinionated default configuration:

$schema: ./node_modules/markdownlint/schema/markdownlint-config-schema.json

line-length: false # Modern editors handle wrapping

Keep the standard rules enabled and disable line-length in this default configuration because:

  • Modern editors and viewers handle text wrapping automatically
  • Fixed line length creates unnecessary friction in most projects
  • Semantic issues are more valuable to catch than presentation issues

Customize other rules when the user requests it or established project requirements call for it.

Comments

Markdown supported