Skip to content

Commit a7fa38b

Browse files
authored
Improved ConsoleLogger to support running in watcher (#7033)
1 parent 4e7ee37 commit a7fa38b

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

src/Watcher.php

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -125,13 +125,18 @@ public function restart($isStart = true)
125125
$this->channel->pop();
126126
$this->output->writeln('Start server ...');
127127

128-
$descriptorspec = [
128+
$descriptorSpec = [
129129
0 => STDIN,
130130
1 => STDOUT,
131131
2 => STDERR,
132132
];
133133

134-
proc_open($this->option->getBin() . ' ' . BASE_PATH . '/' . $this->option->getCommand(), $descriptorspec, $pipes);
134+
proc_open(
135+
$this->option->getBin() . ' ' . BASE_PATH . '/' . $this->option->getCommand(),
136+
$descriptorSpec,
137+
$pipes,
138+
env_vars: $_ENV
139+
);
135140

136141
$this->output->writeln('Stop server success.');
137142
$this->channel->push(1);

0 commit comments

Comments
 (0)