drizzle/init
Source
Usage
bash
npm exec saf-workflow kickoff drizzle/init <name> <path>To run this workflow automatically, tell the agent to:
- Navigate to the target package
- Run this command
- Follow the instructions until done
Checklist
When run, the workflow will:
- Copy template files and rename placeholders.
- Upsert package.json from template
- Upsert drizzle.config.ts from template
- Upsert schema.ts from template
- Upsert instances.ts from template
- Upsert errors.ts from template
- Upsert types.ts from template
- Upsert index.ts from template
- Upsert tsconfig.json from template
- Upsert vitest.config.js from template
- Upsert .gitignore from template
- Upsert index.test.ts from template
- Change working directory to services/example-service/example-db
- Run
npm install - Run
npm run generate - Run
mkdir -p data - Run
touch data/.gitkeep - Run
npm test
Help Docs
bash
Usage: npm exec saf-workflow kickoff drizzle/init <name> <path>
Create a Drizzle/SQLite database package
Arguments:
name The name of the database package to create (e.g., 'user-db' or 'analytics-db')
Example: "@example-org/example-db"
path The path to the target directory for the database package (e.g., './services/example-db')
Example: "./services/example-service/example-db"