bdy 1.15.2-dev → 1.15.3-dev
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/distTs/package.json
CHANGED
|
@@ -178,13 +178,16 @@ class ServerSsh extends events_1.default {
|
|
|
178
178
|
else
|
|
179
179
|
opts.env.PATH = `${process.env.PATH};C:\\Windows\\System32\\WindowsPowerShell\\v1.0`;
|
|
180
180
|
}
|
|
181
|
-
(0, child_process_1.
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
181
|
+
const proc = (0, child_process_1.spawn)(command, opts);
|
|
182
|
+
proc.stdout.on('data', (data) => {
|
|
183
|
+
stream.write(data);
|
|
184
|
+
});
|
|
185
|
+
proc.stderr.on('data', (data) => {
|
|
186
|
+
stream.stderr.write(data);
|
|
187
|
+
});
|
|
188
|
+
proc.once('close', (code) => {
|
|
189
|
+
stream.exit(code || 0);
|
|
190
|
+
stream.end();
|
|
188
191
|
const [seconds, nano] = process.hrtime(s);
|
|
189
192
|
const ms = seconds * 1000 + nano / 1000 / 1000;
|
|
190
193
|
logger_1.default.debug(`local ssh exec ends: ${ms}ms`);
|