git ssb

0+

cel-desktop / ssb-pkg



Tree: cfc8d49135488f7554210234b3a503c2dbd6c6a5

Files: cfc8d49135488f7554210234b3a503c2dbd6c6a5 / test / test-50-spawn / test-execFile.js

508 bytesRaw
1#!/usr/bin/env node
2
3'use strict';
4
5var execFile = require('child_process').execFile;
6
7var child = execFile(
8 process.execPath, [
9 require.resolve('./test-execFile-child.js'), 'argvx', '--argvy'
10 ],
11 function (error) {
12 if (error) return console.error(error);
13 console.log('execFile done');
14 }
15);
16
17child.stdout.pipe(process.stdout);
18child.stderr.pipe(process.stderr);
19
20child.on('exit', function (code) {
21 setTimeout(function () {
22 console.log('Child exited with code', code);
23 }, 100);
24});
25

Built with git-ssb-web