Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

content-file-validator

БесплатноЗапускает вложенные скриптыНе проверен

validate markdown, template and documentation files for markdown quality, yaml frontmatter schema compliance, required semver version fields, version…

lightspeedwpот lightspeedwp★ 20 звёзд на GitHub

Об этом скилле

Content File Validator

Use this skill when the user wants one reusable validation pass over documentation, Markdown, templates, or mixed content files that need both structural Markdown checks and YAML frontmatter validation.

When to use this combined validator

Run this skill when the request involves any of the following:

  • validating Markdown quality or document structure
  • checking heading order, duplicate headings, empty headings, or obvious Markdown problems
  • checking malformed links or obviously broken local links where they can be verified safely
  • enforcing required YAML frontmatter at the top of each file
  • validating frontmatter against a configurable schema
  • requiring a version field that follows SemVer MAJOR.MINOR.PATCH
  • checking whether changed files appear to need a version increment when a base Git reference is available
  • producing one consolidated validation report instead of separate Markdown and frontmatter reports

Do not use this skill for general prose critique, broad style editing, or auto-fixing content unless the user explicitly asks for that workflow.

Default scope and file types

By default, scan files/ recursively and include:

  • .md
  • .mdx
  • .html
  • .php
  • .twig
  • .njk
  • .liquid
  • .yml
  • .yaml

Allow configurable include and exclude globs. Use the built-in defaults unless the user narrows the scope.

How Markdown validation works

For Markdown-style files, validate:

  • exactly one H1 when the file is document-style
  • heading level order without jumps such as H2 to H4
  • empty headings
  • repeated headings when they look accidental
  • malformed inline links
  • obviously broken local file links when the target can be checked from the current filesystem
  • trailing structural issues that make the document look unfinished or invalid

Use references/markdown-validation-rules.md as the source of truth for these checks and their intended interpretation.

How frontmatter validation works

For all matching files, validate that:

  1. the file begins with YAML frontmatter at the very top
  2. nothing appears before the opening ---
  3. the frontmatter parses safely as a YAML object
  4. required fields are present
  5. field types, enums, patterns, and property limits satisfy the schema
  6. unknown fields are allowed or rejected according to the schema
  7. per-file-type overrides are applied where the schema defines them

Use references/frontmatter.schema.yaml as the source of truth for metadata rules.

How SemVer version checks work

Every validated document must include:

version: "1.0.0"

Validate version as SemVer MAJOR.MINOR.PATCH.

When --enforce-version-increment and a usable --base-ref are provided:

  • compare each changed file with the base reference when possible
  • fail when file content changed but the version value did not change
  • warn when the file changed and the version changed, but the correct increment type cannot be inferred safely from the diff alone
  • do not guess whether the change should be MAJOR, MINOR, or PATCH; ask the user to confirm the intended change type when it matters

Use references/semver-versioning-rules.md for the human rules behind version increments.

Inputs to confirm

Before validating, identify:

  1. the target directory to scan
  2. the schema file to use
  3. any include globs that narrow the scan
  4. any exclude globs that should be added to the defaults
  5. whether version increment checks should be enforced
  6. which base Git reference to compare against, when version-increment validation is requested
  7. whether the user wants report-only output or explicit fix suggestions

Default assumptions when the user does not specify them:

  • target directory: files/
  • schema file: references/frontmatter.schema.yaml
  • output format: consolidated Markdown report
  • behaviour: validate and suggest fixes only
  • overwrite policy: never modify files unless the user explicitly asks for that

Validation workflow

  1. Locate the target directory.
  2. Recursively collect matching files using the configured include and exclude globs.
  3. Validate YAML frontmatter placement and schema compliance.
  4. Validate Markdown structure for Markdown-like files.
  5. Validate the required version field and SemVer pattern.
  6. If version increment enforcement is enabled, compare current files against the supplied base reference when available.
  7. Produce one consolidated Markdown report covering summary metrics, failures, warnings, and suggested fixes.
  8. Only propose rewrites when the user explicitly asks for modification or auto-fix behaviour.

How to customise schemas

Customise metadata rules in references/frontmatter.schema.yaml instead of changing the validator logic.

Use references/schema-customisation.md to adapt:

  • required fields
  • enum values
  • type rules
  • property limits
  • defaults used in suggested fixes
  • per-file-type overrides

How to interpret reports

Treat the report in three layers:

Полный SKILL.md на GitHub

Установить content-file-validator в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

Вложенные файлы

README.mdagents/openai.yamlreferences/example-validation-report.mdreferences/frontmatter.schema.yamlreferences/markdown-validation-rules.mdreferences/schema-customisation.mdreferences/semver-versioning-rules.mdrequirements.txtscripts/validate_content_files.pyscripts/validate_markdown_content.py

FAQ

Что делает скилл content-file-validator?

validate markdown, template and documentation files for markdown quality, yaml frontmatter schema compliance, required semver version fields, version increments, broken structure, missing metadata, invalid values, and consolidated content quality reporting.

Как установить скилл content-file-validator?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл content-file-validator запускает скрипты?

Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.

Похожие скиллы

Сравнить content-file-validator с