Skip to main content
ClaudeWave
EN, English
Slash Command215 repo starsupdated 4mo ago

new-command

The new-command slash command scaffolds a new Claude Code command file under .claude/commands/ with proper frontmatter and structure, registers it in both CLAUDE.md and README.md index files, and validates that the command name does not already exist. Use this when extending a ROS2 Claude Code template with additional slash commands that orchestrate paired skills.

Install in Claude Code
Copy
mkdir -p ~/.claude/commands && curl -fsSL https://raw.githubusercontent.com/harunkurtdev/ros2-claude-code-template/HEAD/.claude/commands/new-command.md -o ~/.claude/commands/new-command.md
Then start a new Claude Code session; the slash command loads automatically.

new-command.md

Add a new `/slash-command` to this `.claude/` config.

Argument handling (`$ARGUMENTS`):
1. `<command_name>` — `kebab-case` (required); becomes the file name and
   the `/command` name.
2. `[paired_skill]` — the skill this command drives (most commands read a
   skill, then act). If missing, ask.
3. `[description]` — one-line imperative summary.

If anything is unclear, ask before writing.

Process:
1. Read the `extending_claude_config` skill (conventions + templates).
2. Verify `commands/<command_name>.md` does not already exist.
3. Create `commands/<command_name>.md` with:
   * frontmatter: `description:` (one-line, imperative),
     `argument-hint:` (`"<arg1> <arg2> [optional]"`),
     `allowed-tools:` (usually `["Bash","Read","Write","Edit"]`).
   * body: a short intro, an **Argument handling (`$ARGUMENTS`)** section,
     a "if anything is missing, ask first" line, and a numbered
     **Process** that (a) reads the paired skill, (b) does the work, and
     (c) prints a summary (files created, the next command to run).
   * match the structure of a sibling command (e.g. `new-node.md`,
     `new-controller.md`).
4. **Index it**: add a row to the **Slash commands** table in
   `.claude/CLAUDE.md`, and to the command list in `.claude/README.md`
   under "How to use".
5. Print: file created + the index rows added.

A command should defer the real "how" to a skill and stay an
orchestration recipe. Always update both indexes in the same change.
behaviortree_node_creationSkill

Scaffold a Behavior Tree leaf node — plain BehaviorTree.CPP (SyncActionNode / StatefulActionNode / ConditionNode) or a BehaviorTree.ROS2 wrapper (RosActionNode / RosServiceNode / RosTopicPubNode / RosTopicSubNode) — with ports, factory/plugin registration, and XML v4 usage. Trigger when the user asks to write a behavior-tree node (not Nav 2-specific).

behaviortree-reviewerSubagent

Use proactively before opening a PR that adds or changes BehaviorTree.CPP nodes or BehaviorTree.ROS2 wrappers (RosActionNode/RosServiceNode/RosTopicPub/SubNode, TreeExecutionServer). Reviews a diff against BT.CPP v4 conventions — node base-class choice, non-blocking ticks, ports/blackboard typing, factory/plugin registration, XML v4, and the ROS 2 wrapper contract. Returns a punch list with file:line anchors, not a rewrite.

buildSlash Command

Build the colcon workspace (optionally a single package) and report the outcome.

clean-arch-architectSubagent

Use when a design decision touches Clean Architecture boundaries in a ROS 2 project — which layer a new behaviour belongs to, whether a port belongs in domain or application, whether a new node should be lifecycle-managed, whether to compose nodes or split packages. Returns an architectural recommendation with trade-offs, not implementation.

commandsSkill

Author a new skill under .claude/skills/<name>/SKILL.md with valid frontmatter, following the template conventions, and index it in CLAUDE.md + README.md.

ecs-architectSubagent

Use when a design decision touches the gz-sim ECS — where new state should live, which system phase should write it, how to avoid coupling, whether to add a component vs. a member variable, whether a new system should be split or merged with an existing one. Returns an architectural recommendation with trade-offs, not implementation.

extending_claude_configSkill

Author a new asset for this .claude/ template — a rule, skill, slash command, or sub-agent — following the project's conventions and wiring it into the CLAUDE.md / README.md indexes. Trigger when the user wants to add or extend a command, skill, agent, or rule (make the template itself extensible).

gz-buildSkill

Configure and build gz-sim from source using either CMake/Ninja directly or a colcon workspace. Trigger when the user asks to build, recompile, configure, or set up the gz-sim binary tree.