plugin-structure
Was er macht
Dieser Skill erklärt den Standard-Ordneraufbau und die Manifestdatei für Claude-Code-Plugins. Er richtet sich an Personen, die ein neues Plugin beginnen oder ein bestehendes ordnen wollen.
Wann du ihn nutzt
- ✓Wenn du ein neues Claude-Code-Plugin von Grund auf erstellen willst.
- ✓Wenn du einem bestehenden Plugin Befehle, Agenten, Skills oder Hooks hinzufügen willst.
- ✓Wenn ein Plugin nicht lädt und du seinen Ordneraufbau prüfen willst.
Link zum Skill
https://github.com/anthropics/claude-plugins-official/blob/main/plugins/plugin-dev/skills/plugin-structure/SKILL.mdKopiere ihn und füge ihn in deine KI ein (Claude, ChatGPT oder Cursor) mit der Bitte, den Anweisungen zu folgen.
So nutzt du ihn
Am einfachsten: Kopiere die Nachricht und füge sie in deine KI ein. Sie liest den Skill und folgt den Anweisungen.
Fertige Nachricht zum Einfügen
Für Claude Code, Codex oder Cursor: Führe den Befehl in deinem Projektordner aus, dann wird der Skill installiert.
Lade die SKILL.md herunter und lege sie in den Skills-Ordner deines Agenten.
Beispielanfrage an deine KI
“Lege für mich ein neues Claude-Code-Plugin mit einem Befehl und einem Skill an.”
5 neue Skills pro Woche. 1 Minute Lesezeit.
So funktioniert es
Jeder Komponententyp hat einen festen Ordner. Claude Code findet Komponenten dort automatisch. Die Datei plugin.json beschreibt das Plugin.
Technischer Inhalt (originale SKILL.md)
Originaltext des Autors, auf Englisch, direkt von GitHub.
Plugin Structure for Claude Code
Overview
Claude Code plugins follow a standardized directory structure with automatic component discovery. Understanding this structure enables creating well-organized, maintainable plugins that integrate seamlessly with Claude Code.
Key concepts:
- Conventional directory layout for automatic discovery
- Manifest-driven configuration in
.claude-plugin/plugin.json - Component-based organization (commands, agents, skills, hooks)
- Portable path references using
${CLAUDE_PLUGIN_ROOT} - Explicit vs. auto-discovered component loading
Directory Structure
Every Claude Code plugin follows this organizational pattern:
plugin-name/
├── .claude-plugin/
│ └── plugin.json # Required: Plugin manifest
├── commands/ # Slash commands (.md files)
├── agents/ # Subagent definitions (.md files)
├── skills/ # Agent skills (subdirectories)
│ └── skill-name/
│ └── SKILL.md # Required for each skill
├── hooks/
│ └── hooks.json # Event handler configuration
├── .mcp.json # MCP server definitions
└── scripts/ # Helper scripts and utilities
Critical rules:
- Manifest location: The
plugin.jsonmanifest MUST be in.claude-plugin/directory - Component locations: All component directories (commands, agents, skills, hooks) MUST be at plugin root level, NOT nested inside
.claude-plugin/ - Optional components: Only create directories for components the plugin actually uses
- Naming convention: Use kebab-case for all directory and file names
Plugin Manifest (plugin.json)
The manifest defines plugin metadata and configuration. Located at .claude-plugin/plugin.json:
Required Fields
{
"name": "plugin-name"
}
Name requirements:
- Use kebab-case format (lowercase with hyphens)
- Must be unique across installed plugins
- No spaces or special characters
- Example:
code-review-assistant,test-runner,api-docs
Recommended Metadata
{
"name": "plugin-name",
"version": "1.0.0",
"description": "Brief explanation of plugin purpose",
"author": {
"name": "Author Name",
"email": "author@example.com",
"url": "https://example.com"
},
"homepage": "https://docs.example.com",
"repository": "https://github.com/user/plugin-name",
"license": "MIT",
"keywords": ["testing", "automation", "ci-cd"]
}
Version format: Follow semantic versioning (MAJOR.MINOR.PATCH) Keywords: Use for plugin discovery and categorization
Component Path Configuration
Specify custom paths for components (supplements default directories):
{
"name": "plugin-name",
"commands": "./custom-commands",
"agents": ["./agents", "./specialized-agents"],
"hooks": "./config/hooks.json",
"mcpServers": "./.mcp.json"
}
Important: Custom paths supplement defaults—they don't replace them. Components in both default directories and custom paths will load.
Path rules:
- Must be relative to plugin root
- Must start with
./ - Cannot use absolute paths
- Support arrays for multiple locations
Component Organization
Commands
Location: commands/ directory
Format: Markdown files with YAML frontmatter
Auto-discovery: All .md files in commands/ load automatically
Example structure:
commands/
├── review.md # /review command
├── test.md # /test command
└── deploy.md # /deploy command
File format:
---
name: command-name
description: Command description
---
Command implementation instructions...
Usage: Commands integrate as native slash commands in Claude Code
Agents
Location: agents/ directory
Format: Markdown files with YAML frontmatter
Auto-discovery: All .md files in agents/ load automatically
Example structure:
agents/
├── code-reviewer.md
├── test-generator.md
└── refactorer.md
File format:
---
description: Agent role and expertise
capabilities:
- Specific task 1
- Specific task 2
---
Detailed agent instructions and knowledge...
Usage: Users can invoke agents manually, or Claude Code selects them automatically based on task context
Skills
Location: skills/ directory with subdirectories per skill
Format: Each skill in its own directory with SKILL.md file
Auto-discovery: All SKILL.md files in skill subdirec
Häufige Fragen
Wo muss die Manifestdatei liegen?
Die Datei plugin.json muss in einem Ordner namens .claude-plugin im Stammordner des Plugins liegen.
Muss ich jede Komponente von Hand auflisten?
Komponenten in den Standardordnern werden automatisch gefunden. Der Skill behandelt aber auch das ausdrückliche Laden.
Wie sollen Plugin-Dateien aufeinander verweisen?
Der Skill empfiehlt die portable Variable ${CLAUDE_PLUGIN_ROOT} für Pfade.
Details
Originalbeschreibung des Autors
This skill should be used when the user asks to "create a plugin", "scaffold a plugin", "understand plugin structure", "organize plugin components", "set up plugin.json", "use ${CLAUDE_PLUGIN_ROOT}", "add commands/agents/skills/hooks", "configure auto-discovery", or needs guidance on plugin directory layout, manifest configuration, component organization, file naming conventions, or Claude Code plugin architecture best practices.
Beliebtheit
- GitHub-Sterne
- 46k
- Platz im Ranking
- #6349
- Lizenz
- Apache-2.0
- Aktualisiert
- 2.11.2026
Kommentare
- …
Weitere Skills aus diesem Repository
access
46kLässt dich festlegen, wer deinem Assistenten über den Discord-Kanal schreiben darf, inklusive Kopplungsfreigaben und Erlaubnislisten.
configure
46kRichtet den Discord-Kanal für deinen Assistenten ein, indem er das Bot-Token speichert und prüft, wer ihn erreichen kann.
access
46kLässt dich festlegen, wer dir über den iMessage-Kanal schreiben darf, inklusive Freigaben und Erlaubnislisten.
configure
46kPrüft deine iMessage-Kanaleinrichtung, inklusive Vollzugriff auf die Festplatte, und erklärt, wer deinen Assistenten erreichen kann.
Ähnliche Skills
diffs
394kLässt deinen Agenten einen echten, teilbaren Diff seiner Änderungen als Viewer-Link oder Bilddatei erstellen, statt einer handgeschriebenen Zusammenfassung.
coding-agent
394kHilft deinem Agenten, eine größere Programmieraufgabe als Hintergrund-Worker an Codex, Claude Code oder OpenCode zu übergeben und danach den Fortschritt zu prüfen.
gh-issues
394kHilft deinem Agenten, GitHub-Issues zu finden, die zu bearbeitenden auszuwählen und Pull Requests mit Korrekturen zu öffnen, einschließlich der Nacharbeit an Review-Kommentaren.