Rules / Format and vendor rules

name-dir-mismatch

Skill name does not match its folder name.

warning by default Format and vendor rules Fix offered, for review Inline suppression allowed

Source: Agent Skills specification (agentskills.io), read 14 October 2026.

On GitHub: the rule doc and the tests.

All rules73

What it catches#

Skill name does not match its folder name.

A SKILL.md whose name differs from the folder it sits in. Only skills that sit directly in a skills folder (.claude/skills/x/SKILL.md, skills/x/SKILL.md) or at the top of the root are checked: a SKILL.md nested inside another skill's folder (the stages of a pipeline) is often prefixed on purpose, and a template/ folder is meant to be copied and renamed. SKILL.md files under tests, fixtures or testdata folders are not checked by any skill format rule.

Why it matters#

The Agent Skills spec expects name to match the folder. Tools that key skills by folder show a different name from the one in the file.

Bad example#

.claude/skills/changelog/SKILL.md
---
name: release-notes
description: Draft release notes from merged PRs. Use when asked for a changelog.
---

The Agent Skills spec says the name must match the parent directory. Claude Code keys skills by folder, so /changelog invokes it, while a user who read the file tries /release-notes and gets nothing. Validators report the mismatch.

Good example#

.claude/skills/release-notes/SKILL.md
---
name: release-notes
description: Draft release notes from merged PRs. Use when asked for a changelog.
---

How to fix#

Rename one side. If the folder name is the one people already type, change name to match it; the suggested fix does exactly that. Otherwise git mv the folder.

asitis can propose this edit. asitis lint --fix-preview prints a unified diff that git apply accepts, and the suggest_fixes MCP tool returns the same diff; nothing is written to disk by either. The fix for this rule needs review before you apply it, because it changes or removes content.

Suppress or configure#

For one finding, put a comment on the line above it. The reason after -- is optional but worth writing:

<!-- asitis-disable-next-line name-dir-mismatch -- why this one is fine -->

For a whole file:

<!-- asitis-disable-file name-dir-mismatch -- why this file is an exception -->

For every file, turn it off or change its severity in .asitisrc.json:

{ "rules": { "name-dir-mismatch": "off" } }

A .asitisrc.json overrides entry limits a change to some paths, and a baseline (asitis lint --format json --write-baseline) accepts today's findings so only new ones fail the build.

Source#

Agent Skills specification, read on 14 October 2026.

This page is generated from the plugin's rule registry. Edit it on GitHub. False positive? Open an issue with the line it fired on.