docs(hero_service_scaffold): per-domain generated/ layout (#96) #280

Merged
timur merged 1 commit from issue-96-generated-folders into development 2026-05-20 23:54:24 +00:00
Owner

Summary

Updates the hero_service_scaffold skill docs (skills/hero/service/hero_service_scaffold.md) to reflect hero_rpc#96, which lands the per-domain generated/ codegen-output separation.

What changed in the docs

  • The big "What the scaffolder produces today" tree now shows the generated/ subfolder under every per-domain dir, with the contributor-facing scaffolded-once files (mod.rs, types.rs, rpc.rs, .gitignore) called out separately from the codegen output.
  • Added a dedicated paragraph explaining the per-domain generated/ separation: why it exists (git status clean after cargo build, sub-30-second readability), what stays committed vs ignored, and where custom impl blocks live (below the include!() in types.rs).
  • Documented the new build-ordering setup: [build-dependencies] hero_<name> plus a tiny build.rs shim on hero_<name>_sdk and hero_<name>_admin so cargo runs the core crate's build.rs (which writes both crates' codegen output) before either is compiled.
  • Documented the gitignore shape: repo-root .gitignore for cross-crate codegen (docs/, sdk/js/src/, sdk/python/*/ with !pyproject.toml exception), per-domain .gitignore files containing just generated/.
  • Updated the existing osis_server_generated.rs callout in the docs/openrpc.json section to point at the new generated/server.rs filename and note the include_str ordering guarantee.

Why

Friend feedback on the hero_service template: it was hard to tell what is codegen vs hand-written. The new layout makes it obvious at a glance. This skill is the canonical reference for anyone scaffolding a new service, so the docs have to match the new shape before anyone copies the old layout.

  • hero_rpc#101 (merged) — the generator + recipe_server changes.
  • hero_service#6 (merged) — applies the new layout to the hero_service template repo.

Test plan

  • Skim the rendered Markdown for any remaining _generated.rs filenames or stale paths
  • Cross-check the layout block against the actual hero_service repo tree post-#6

Generated with Claude Code.

## Summary Updates the `hero_service_scaffold` skill docs (`skills/hero/service/hero_service_scaffold.md`) to reflect hero_rpc#96, which lands the per-domain `generated/` codegen-output separation. ## What changed in the docs - The big "What the scaffolder produces today" tree now shows the `generated/` subfolder under every per-domain dir, with the contributor-facing scaffolded-once files (`mod.rs`, `types.rs`, `rpc.rs`, `.gitignore`) called out separately from the codegen output. - Added a dedicated paragraph explaining the per-domain `generated/` separation: why it exists (`git status` clean after `cargo build`, sub-30-second readability), what stays committed vs ignored, and where custom `impl` blocks live (below the `include!()` in `types.rs`). - Documented the new build-ordering setup: `[build-dependencies] hero_<name>` plus a tiny `build.rs` shim on `hero_<name>_sdk` and `hero_<name>_admin` so cargo runs the core crate's `build.rs` (which writes both crates' codegen output) before either is compiled. - Documented the gitignore shape: repo-root `.gitignore` for cross-crate codegen (`docs/`, `sdk/js/src/`, `sdk/python/*/` with `!pyproject.toml` exception), per-domain `.gitignore` files containing just `generated/`. - Updated the existing `osis_server_generated.rs` callout in the `docs/openrpc.json` section to point at the new `generated/server.rs` filename and note the include_str ordering guarantee. ## Why Friend feedback on the `hero_service` template: it was hard to tell what is codegen vs hand-written. The new layout makes it obvious at a glance. This skill is the canonical reference for anyone scaffolding a new service, so the docs have to match the new shape before anyone copies the old layout. ## Related PRs - `hero_rpc#101` (merged) — the generator + recipe_server changes. - `hero_service#6` (merged) — applies the new layout to the hero_service template repo. ## Test plan - [ ] Skim the rendered Markdown for any remaining `_generated.rs` filenames or stale paths - [ ] Cross-check the layout block against the actual `hero_service` repo tree post-#6 Generated with Claude Code.
Updates the `hero_service_scaffold` skill to reflect hero_rpc#96:

- Per-domain `generated/` subfolders that hold all codegen output
- Gitignored everywhere they appear; contributor-facing `mod.rs`,
  `types.rs` (with `include!()` wrapper), `rpc.rs` (trait impl site)
  are scaffolded once and never overwritten
- `[build-dependencies] hero_<name>` on consumer crates (`*_sdk`,
  `*_admin`) plus a tiny `build.rs` shim — forces cargo to run the
  core crate's `build.rs` before either is compiled, so the
  gitignored codegen output is on disk when downstream crates start
- Repo-root + per-domain `.gitignore` files scaffolded once

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
timur merged commit 5af82d8c7e into development 2026-05-20 23:54:24 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
lhumina_code/hero_skills!280
No description provided.