From 73c8a9a257fb9b32a6fa2bb408de45e775df9427 Mon Sep 17 00:00:00 2001 From: Sainan <63328889+Sainan@users.noreply.github.com> Date: Sun, 22 Jun 2025 23:23:55 +0200 Subject: [PATCH] actually prettier --- scripts/dev.js | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/scripts/dev.js b/scripts/dev.js index b689e130..542528f1 100644 --- a/scripts/dev.js +++ b/scripts/dev.js @@ -14,6 +14,7 @@ args.push("--secret"); args.push(secret); let buildproc, runproc; +const spawnopts = { stdio: "inherit", shell: true }; function run(changedFile) { if (changedFile) { console.log(`Change to ${changedFile} detected`); @@ -28,10 +29,7 @@ function run(changedFile) { runproc = undefined; } - const thisbuildproc = spawn("npm", ["run", process.versions.bun ? "verify" : "build:dev"], { - stdio: "inherit", - shell: true - }); + const thisbuildproc = spawn("npm", ["run", process.versions.bun ? "verify" : "build:dev"], spawnopts); const thisbuildstart = Date.now(); buildproc = thisbuildproc; buildproc.on("exit", code => { @@ -41,10 +39,7 @@ function run(changedFile) { buildproc = undefined; if (code === 0) { console.log(`${process.versions.bun ? "Verified" : "Built"} in ${Date.now() - thisbuildstart} ms`); - runproc = spawn("npm", ["run", process.versions.bun ? "bun-run" : "start", "--", ...args], { - stdio: "inherit", - shell: true - }); + runproc = spawn("npm", ["run", process.versions.bun ? "bun-run" : "start", "--", ...args], spawnopts); runproc.on("exit", () => { runproc = undefined; });