Command Development

Create Claude Code slash commands with frontmatter, arguments, file references, and bash execution.

Updated Mar 22, 2026
One-click install
npx skills add https://github.com/ace8991/agentos --skill command-development-ace8991
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: Command Development
Source: https://github.com/ace8991/agentos/tree/main/.tmp_claude_code/claude-code-main/plugins/plugin-dev/skills/command-development
Command: npx skills add https://github.com/ace8991/agentos --skill command-development-ace8991

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Writing effective Claude Code slash commands requires knowing the Markdown file format, YAML frontmatter fields, dynamic argument syntax, and plugin-specific conventions, which are easy to get wrong without structured guidance. ## Core Features & Use Cases - Command Authoring Guidance: Covers file format, locations (project, personal, plugin), frontmatter fields like description, allowed-tools, model, and argument-hint. - Dynamic Features: Explains $ARGUMENTS and positional arguments, @ file references, and inline bash execution for context-aware commands. - Plugin Integration: Documents ${CLAUDE_PLUGIN_ROOT} usage, command namespacing, and coordination with plugin agents, skills, and hooks. - Use Case: When you ask to create a /review-pr command that takes a PR number, runs git checks, and restricts tools to Bash(git:*), this Skill provides the exact structure, frontmatter, and validation patterns to produce a working command. ## Quick Start Ask the agent to create a slash command for your workflow, for example a code review command with a PR number argument and git-only bash access.

Frequently Asked Questions about Command Development

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

FAQPage Schema
How do I create a slash command in Claude Code?

Create a Markdown file in .claude/commands/ for project commands or ~/.claude/commands/ for personal commands. The file content becomes the prompt Claude executes, and optional YAML frontmatter configures description, allowed-tools, model, and argument-hint.

How do I add arguments to a Claude Code slash command?

Use $ARGUMENTS to capture all arguments as one string, or positional variables like $1, $2, $3 for individual arguments. Document expected arguments with the argument-hint frontmatter field so users see them in autocomplete.

What frontmatter fields does a slash command support?

Slash commands support description, allowed-tools, model (sonnet, opus, haiku), argument-hint, and disable-model-invocation. All fields are optional, and commands work with no frontmatter at all.

Can a slash command run bash commands or read files?

Yes. Use !`command` syntax to execute bash and include output, and @path/to/file to include file contents. Bash execution requires the command to allow the Bash tool via allowed-tools, ideally scoped like Bash(git:*).

Why is my slash command not appearing in Claude Code?

Check that the file is in the correct commands directory, has a .md extension, and contains valid Markdown. Restart Claude Code after adding the file, and verify YAML frontmatter syntax is valid if used.

How do plugin commands differ from project commands?

Plugin commands live in a plugin's commands/ directory and are discovered automatically when the plugin is installed. They can use ${CLAUDE_PLUGIN_ROOT} to reference plugin scripts, templates, and configuration portably across installations.