From e0adeee48eeb0d5412aa5c0258f7c12e6b1c38ed Mon Sep 17 00:00:00 2001 From: James Judd Date: Wed, 16 Feb 2022 03:13:16 +1100 Subject: [PATCH] revert: migration:show command must exist with zero status code (Fixes #7349) (#8185) * feat: add --quiet option to migration:show command * adding process.exit(0) back * Update MigrationShowCommand.ts Co-authored-by: Umed Khudoiberdiev --- src/commands/MigrationShowCommand.ts | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/commands/MigrationShowCommand.ts b/src/commands/MigrationShowCommand.ts index aa208b18e2..0ca11840cf 100644 --- a/src/commands/MigrationShowCommand.ts +++ b/src/commands/MigrationShowCommand.ts @@ -43,11 +43,10 @@ export class MigrationShowCommand implements yargs.CommandModule { logging: ["query", "error", "schema"] }); connection = await createConnection(connectionOptions); - const unappliedMigrations = await connection.showMigrations(); + await connection.showMigrations(); await connection.close(); - // return error code if there are unapplied migrations for CI - process.exit(unappliedMigrations ? 1 : 0); + process.exit(0); } catch (err) { if (connection) await (connection as Connection).close();