Skip to content

Commit b7c303a

Browse files
committed
[refactor] Implement silent fork via spawn stdio options.
1 parent 4fed919 commit b7c303a

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

lib/forever/monitor.js

+2-5
Original file line numberDiff line numberDiff line change
@@ -214,11 +214,8 @@ Monitor.prototype.trySpawn = function () {
214214
this.spawnWith.env = this._getEnv();
215215

216216
if (this.fork) {
217-
this.spawnWith.silent = true;
218-
return fork(
219-
path.join(__dirname, '..', '..', 'bin', 'fork-shim'),
220-
[this.command].concat(this.args), this.spawnWith
221-
);
217+
this.spawnWith.stdio = [ 'pipe', 'pipe', 'pipe', 'ipc' ];
218+
return spawn(this.command, this.args, this.spawnWith);
222219
}
223220

224221
return spawn(this.command, this.args, this.spawnWith);

0 commit comments

Comments
 (0)