Merge pull request #1658 from paperclipai/fix/migration-auto-apply-precedence

fix(server): check MIGRATION_AUTO_APPLY before MIGRATION_PROMPT
This commit is contained in:
Devin Foley
2026-03-24 15:56:00 -07:00
committed by GitHub

View File

@@ -94,8 +94,8 @@ export async function startServer(): Promise<StartedServer> {
}
async function promptApplyMigrations(migrations: string[]): Promise<boolean> {
if (process.env.PAPERCLIP_MIGRATION_PROMPT === "never") return false;
if (process.env.PAPERCLIP_MIGRATION_AUTO_APPLY === "true") return true;
if (process.env.PAPERCLIP_MIGRATION_PROMPT === "never") return false;
if (!stdin.isTTY || !stdout.isTTY) return true;
const prompt = createInterface({ input: stdin, output: stdout });