Idempotent Seed Script

Write data-seed scripts (add-product, add-user, migrate-data, bootstrap-tenant) to be idempotent — detect existing records and skip rather than duplicate or fail — and run them with a targeted grep (added/skip/error) so the outcome is visible in one line. Use when seeding data into a database or service (e-commerce products, tenants, users, reference data), especially scripts that may be re-run.

jcdavis131 Updated

File contents

jcdavis131/cursor-agent-skills/tree/main/skills/idempotent-seed-script commit 1ba022cb32

Frequently asked questions

npx skillmds@latest add jcdavis131/idempotent-seed-script