Part I: Foundations

The create-workiq scaffolder

One command bootstraps a production-shaped app with tests, CI, and deploy wired.

Chapter 20 · 10 min read

The scaffolder is where the opinions live. One command generates a repo that has everything you need to ship, and nothing you don't.

The command

bun run create-workiq --name="MyApp" --yes --data=do-sqlite

Flags:

`--name`: the app name. Slugified for directory + Worker binding names.

`--data`: `do-sqlite` (default), `d1`, or `bun-sqlite`. Controls the data layer.

`--browser`: adds a Playwright / Browser Rendering tier.

`--extras`: comma-separated. Any of `queues,workflows,vectorize,email` adds bindings + wrangler config.

What it emits

Three sibling directories. `src/` is the core (Hono app factory, sync repo, Zod contracts). `web/` is the Astro console (the house UI system, ready to add pages). `cloudflare/` is the edge deployment (front-door Worker, DO, wrangler config, D1 migrations).

Plus: a Makefile with the deploy ritual, a flock harness for local runs, a Starlight docs site, and a CI workflow.