refactor(cli): centralize process lifecycle

This commit is contained in:
James
2026-07-20 09:04:03 -07:00
parent 6ad738b580
commit 3aa2404747
71 changed files with 812 additions and 434 deletions
+2 -1
View File
@@ -1,3 +1,4 @@
import { failCommand } from "../utils/commandResult.js";
import { cpSync, existsSync, mkdirSync, mkdtempSync, renameSync, rmSync, statSync } from "node:fs";
import { tmpdir } from "node:os";
import { basename, dirname, extname, join } from "node:path";
@@ -407,7 +408,7 @@ export default defineCommand({
} else {
console.error(`\n${c.error("✗")} Compare failed: ${message}`);
}
process.exit(1);
failCommand();
}
},
});