blob: e55c7bf896d4d39f2fc6f16bbe2f173304d6eb64 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
const spawn = require('child_process').spawn,
path = require('path'),
childPath = path.join(__dirname, 'child-process-persistent.js');
var child = spawn(process.execPath, [ childPath ], {
detached: true,
stdio: 'ignore'
});
console.log(child.pid);
child.unref();
|