mirror of
https://github.com/QuiteAFancyEmerald/Holy-Unblocker.git
synced 2025-05-12 11:30:01 -04:00
More Windows support testing
This commit is contained in:
parent
6b9b889b0e
commit
3f6872f810
2 changed files with 13 additions and 1 deletions
|
@ -13,6 +13,7 @@
|
||||||
"pm2-stop": "pm2 stop ecosystem.config.js",
|
"pm2-stop": "pm2 stop ecosystem.config.js",
|
||||||
"pm2-monit": "pm2 monit",
|
"pm2-monit": "pm2 monit",
|
||||||
"manual-start": "node run-command.mjs start",
|
"manual-start": "node run-command.mjs start",
|
||||||
|
"kill": "node run-command.mjs stop kill",
|
||||||
"build": "node run-command.mjs build && cd lib/rammerhead && npm install && npm run build",
|
"build": "node run-command.mjs build && cd lib/rammerhead && npm install && npm run build",
|
||||||
"start-test-server": "timeout 5 node backend.js; test $? -eq 124 && ( npm run manual-start & ) || exit 1",
|
"start-test-server": "timeout 5 node backend.js; test $? -eq 124 && ( npm run manual-start & ) || exit 1",
|
||||||
"proxy-validator": "node proxyServiceValidator.js"
|
"proxy-validator": "node proxyServiceValidator.js"
|
||||||
|
|
|
@ -27,7 +27,7 @@ for(let i = 2; i < process.argv.length; i++)
|
||||||
console.log(stdout);
|
console.log(stdout);
|
||||||
});
|
});
|
||||||
else if (process.platform === "win32")
|
else if (process.platform === "win32")
|
||||||
exec("START", ['""', "node", "backend.js"], (error, stdout) => {
|
exec("START", ["/MIN", '""', '"node backend.js"'], (error, stdout) => {
|
||||||
if (error) throw error;
|
if (error) throw error;
|
||||||
console.log(stdout);
|
console.log(stdout);
|
||||||
});
|
});
|
||||||
|
@ -81,7 +81,18 @@ for(let i = 2; i < process.argv.length; i++)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
case "kill":
|
||||||
|
if (process.platform === "win32")
|
||||||
|
exec("taskkill", ["/F", "/IM", "node*"], (error, stdout) => {
|
||||||
|
console.log(stdout);
|
||||||
|
});
|
||||||
|
else exec("pkill", ["node"], (error, stdout) => {
|
||||||
|
console.log(stdout);
|
||||||
|
});
|
||||||
|
break;
|
||||||
|
|
||||||
// No default case.
|
// No default case.
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue