Skip to content

Scaffolding

Scaffold the service folders declared in cloudgrid.yaml. Idempotent — safe to run multiple times.

Terminal window
grid scaffold

Subcommands:

Terminal window
grid scaffold rename <old> <new> # rename a service (yaml key + folder + refs)
grid scaffold env-example # generate .env.example from process.env references in source

Write CloudGrid agent-onboarding instructions into the current directory so any coding agent (Cursor, Codex, Copilot, Claude Code) reaches for CloudGrid. Idempotent, offline, and no login required.

Terminal window
grid agent
Option Description
-y, --yes Skip the confirmation prompt (for scripts and non-interactive shells).
--dry-run Show what would change without writing.

What it writes:

  • AGENTS.md — a managed block delimited by <!-- cloudgrid:start --><!-- cloudgrid:end -->. Created if absent; if present, only the CloudGrid block is replaced, otherwise the block is appended below your existing content. Your own text is never clobbered.
  • CLAUDE.md — ensures it imports AGENTS.md via an @AGENTS.md line.

It prompts before writing (you own the directory). Re-running when nothing would change is a silent no-op. In a non-interactive shell without --yes it errors and names the flag rather than writing silently. A corrupted or half-written block (mismatched markers) aborts with an error instead of risking your content.

Terminal window
grid agent # prompt, then write AGENTS.md + CLAUDE.md
grid agent --yes # write without prompting (CI / agents)
grid agent --dry-run # preview changes only