Codegen Add Shell Entity

Table of Contents

When to use this skill

When you need to add REPL commands for a new entity in ores.shell. Prerequisites: the domain type must exist (domain-type-creator), the server-side handlers and messaging protocol must be implemented, and table I/O must be available for list output. See Entity lifecycle for the full layer ordering.

How to use this skill

  1. Gather requirements: entity name, menu name (plural), operations needed (list, add, history, delete), parameters for each operation.
  2. Phase 1 — list + add (PR: [shell] Add {entity} list and add commands): create {entity}_commands.hpp and .cpp; create submenu, register list and add; wire into application.cpp.
  3. Phase 2 — history (PR: [shell] Add {entity} history command): add process_get_{entity}_history and register history subcommand.
  4. Phase 3 — recipe docs (PR: [doc] Add {entity} shell command recipes): add how_do_i_*.org recipes under doc/recipes/shell/.

Use feature-branch-manager between phases and pr-manager to open each PR. Build after every step: cmake --build --preset linux-clang-debug-ninja --target ores.shell.

Recipes

Reference

Codegen gap

❌ No codegen profile exists for ores.shell. Do not hand-code this layer. When entity-creator reaches this layer:

  1. Raise a sprint story: "Implement codegen profile for shell REPL commands."
  2. Reference Entity lifecycle§"Codegen gaps" for what the profile must cover.
  3. Link the story to the entity task before marking this layer done.
  4. Once the profile is merged, regenerate and discard any hand-written code.

Until the gap is resolved, this layer is incomplete.

Emacs 29.1 (Org mode 9.6.6)