Summary
Add a companion bootstrap script for applying CMD scaffolding to an already-created repository.
Problem
scripts/seed-repo.sh is optimized for creating a new repository from scratch. Many real teams will already have service repositories and need a safe way to add the CMD workflow to those repos without recreating them.
Proposed enhancement
Add scripts/seed-existing-repo.sh that:
- targets an existing repository directory
- validates that the target is already a git repository or offers a clear mode for handling a non-git directory
- applies a selected repo profile such as
ui, api, worker, data, fullstack, or platform
- copies the shared CMD assets listed in the manifests
- creates local bootstrap files when missing
- avoids overwriting existing files without explicit confirmation or flags
- reports which files were created, skipped, or would conflict
Expected benefit
- easier adoption in brownfield repos
- safer rollout of CMD across multi-repo systems
- less manual copying and lower risk of inconsistent repo setup
- better path for gradually standardizing existing service repos
Acceptance criteria
seed-existing-repo.sh supports the same repo types as seed-repo.sh
- the script detects and reports file conflicts clearly
- the script does not overwrite existing files by default
- bootstrap docs explain when to use
seed-repo.sh vs seed-existing-repo.sh
- the resulting repo includes the same local bootstrap structure expected by CMD
Summary
Add a companion bootstrap script for applying CMD scaffolding to an already-created repository.
Problem
scripts/seed-repo.shis optimized for creating a new repository from scratch. Many real teams will already have service repositories and need a safe way to add the CMD workflow to those repos without recreating them.Proposed enhancement
Add
scripts/seed-existing-repo.shthat:ui,api,worker,data,fullstack, orplatformExpected benefit
Acceptance criteria
seed-existing-repo.shsupports the same repo types asseed-repo.shseed-repo.shvsseed-existing-repo.sh