plugin-structure

Define Claude Code plugin structure with manifest configuration and component directories.

1|Updated Apr 30, 2025
One-click install
npx skills add https://github.com/lucasfth/config --skill plugin-structure-lucasfth
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: plugin-structure
Source: https://github.com/lucasfth/config/tree/main/.claude/plugins/marketplaces/claude-plugins-official/plugins/plugin-dev/skills/plugin-structure
Command: npx skills add https://github.com/lucasfth/config --skill plugin-structure-lucasfth

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This skill provides structured guidance for building and understanding Claude Code plugins, covering directory layout, manifest configuration, and component organization to reduce setup time and errors.

Core Features & Use Cases

  • Directory structure guidance for commands, agents, skills, and hooks
  • Clear manifest guidance for .claude-plugin/plugin.json
  • Auto-discovery and portable path references around ${CLAUDE_PLUGIN_ROOT}
  • Best practices, naming conventions, and troubleshooting patterns
  • Practical patterns and examples for plugin scaffolding

Quick Start

Create a minimal plugin following the recommended layout, add a plugin.json manifest, and enable the plugin to trigger automatic component discovery.

Frequently Asked Questions about plugin-structure

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
What is the recommended directory structure for a Claude Code plugin?

Claude Code plugin structure organizes components into dedicated directories for commands, agents, skills, and hooks. This layout ensures reliable auto-discovery and consistent plugin behavior across different environments.

How do I configure a plugin manifest for Claude Code?

Plugin manifest configuration uses a .claude-plugin/plugin.json file. This manifest defines the plugin's core metadata and enables automatic discovery of its commands, agents, skills, and hooks.

How does auto-discovery work for Claude Code plugin components?

Auto-discovery works by scanning standard component directories using portable path references like ${CLAUDE_PLUGIN_ROOT}. This ensures components are found reliably without manual registration.

What naming conventions should I use for Claude Code plugins?

Claude Code plugins should use kebab-case naming conventions. The SKILL.md file must also include YAML frontmatter to ensure proper parsing and integration within the plugin structure.

Why are my Claude Code plugin components not loading correctly?

Plugin components fail to load when the directory structure deviates from the standard layout or when path references are not portable. Using ${CLAUDE_PLUGIN_ROOT} ensures cross-environment deployment works correctly.