Skip to content

Commit 9f3ffdb

Browse files
lerarosaleneremy
authored andcommitted
One more fix
1 parent abc8522 commit 9f3ffdb

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

lib/monitor/run.js

+7-2
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,7 @@ function run(options) {
9090
sh = process.env.comspec || 'cmd';
9191
shFlag = '/d /s /c';
9292
spawnOptions.windowsVerbatimArguments = true;
93+
spawnOptions.windowsHide = true;
9394
}
9495

9596
var args = runCmd ? utils.stringify(executable, cmd.args) : ':';
@@ -122,11 +123,15 @@ function run(options) {
122123
var forkArgs = cmd.args.slice(1);
123124
var env = utils.merge(options.execOptions.env, process.env);
124125
stdio.push('ipc');
125-
child = fork(options.execOptions.script, forkArgs, {
126+
const forkOptions = {
126127
env: env,
127128
stdio: stdio,
128129
silent: !hasStdio,
129-
});
130+
};
131+
if (utils.isWindows) {
132+
forkOptions.windowsHide = true;
133+
}
134+
child = fork(options.execOptions.script, forkArgs, forkOptions);
130135
utils.log.detail('forking');
131136
debug('fork', sh, shFlag, args);
132137
} else {

0 commit comments

Comments
 (0)