MCPcopy Index your code
hub / github.com/nodejs/node / run

Function run

test/fixtures/eval/stdin_typescript.js:7–16  ·  view source on GitHub ↗
(cmd, strict, cb)

Source from the content-addressed store, hash-verified

5const spawn = require('child_process').spawn;
6
7function run(cmd, strict, cb) {
8 const args = ['--disable-warning=ExperimentalWarning'];
9 if (strict) args.push('--use_strict');
10 args.push('-p');
11 const child = spawn(process.execPath, args);
12 child.stdout.pipe(process.stdout);
13 child.stderr.pipe(process.stdout);
14 child.stdin.end(cmd);
15 child.on('close', cb);
16}
17
18const queue =
19 [

Callers 1

goFunction · 0.70

Calls 4

spawnFunction · 0.50
pushMethod · 0.45
endMethod · 0.45
onMethod · 0.45

Tested by

no test coverage detected