@@ 144-149 (lines=6) @@ | ||
141 | */ |
|
142 | private function connect(array $hosts) |
|
143 | { |
|
144 | $callback = function (string $output) { |
|
145 | $output = preg_replace('/\n$/', '', $output); |
|
146 | if (strlen($output) !== 0) { |
|
147 | $this->output->writeln($output); |
|
148 | } |
|
149 | }; |
|
150 | ||
151 | // Connect to each host sequentially, to prevent getting locked. |
|
152 | foreach ($hosts as $host) { |
|
@@ 195-200 (lines=6) @@ | ||
192 | return 0; |
|
193 | } |
|
194 | ||
195 | $callback = function (string $output) { |
|
196 | $output = preg_replace('/\n$/', '', $output); |
|
197 | if (strlen($output) !== 0) { |
|
198 | $this->output->writeln($output); |
|
199 | } |
|
200 | }; |
|
201 | ||
202 | /** @var Process[] $processes */ |
|
203 | $processes = []; |