mirror of
https://github.com/civitai/civitai.git
synced 2026-09-20 22:08:18 +08:00
4a9dd8246a
`db:migrate:empty` built a cwd-relative `prisma/migrations` path, which is the pre-monorepo location. The schema — and the only migrations directory with a `migration_lock.toml` — moved to packages/civitai-db-schema, so new migrations landed in a directory Prisma no longer reads. Roughly a third of the migrations added since May 2026 ended up there. Derive the directory from package.json's `prisma.schema` so it follows the schema if it moves again, and anchor on the script's own location so the result no longer depends on the cwd it was invoked from. Existing migrations in the root directory are left alone; consolidating them is a separate call.
2.5 KiB
2.5 KiB