MCPcopy Create free account
hub / github.com/Fibi66/FeiControl / runNext

Function runNext

scripts/dev-server.cjs:25–42  ·  view source on GitHub ↗
(args, env)

Source from the content-addressed store, hash-verified

23}
24
25function runNext(args, env) {
26 return new Promise((resolve, reject) => {
27 const child = spawn(process.execPath, [nextBin, ...args], {
28 stdio: ['ignore', 'inherit', 'inherit'],
29 env,
30 });
31
32 child.on('exit', (code, signal) => {
33 if (signal) {
34 process.kill(process.pid, signal);
35 return;
36 }
37 resolve(code ?? 0);
38 });
39
40 child.on('error', reject);
41 });
42}
43
44function spawnNext(args, env) {
45 return spawn(process.execPath, [nextBin, ...args], {

Callers 1

mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected