@sjawhar/pi-envoy 10.6.0 → 10.6.1
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/dist/dispatch.js +12 -4
- package/package.json +1 -1
package/dist/dispatch.js
CHANGED
|
@@ -19251,9 +19251,17 @@ async function runDispatchCli(argv, rawEnv, io) {
|
|
|
19251
19251
|
|
|
19252
19252
|
// ../envoy-client/bin/dispatch.ts
|
|
19253
19253
|
var readText = (path2) => readFileSync4(path2 === "-" ? 0 : path2, "utf-8");
|
|
19254
|
-
|
|
19255
|
-
|
|
19256
|
-
|
|
19254
|
+
var pending = [];
|
|
19255
|
+
var writeTo = (stream) => (text) => {
|
|
19256
|
+
const { promise: promise2, resolve: resolve2 } = Promise.withResolvers();
|
|
19257
|
+
stream.write(text, () => resolve2());
|
|
19258
|
+
pending.push(promise2);
|
|
19259
|
+
};
|
|
19260
|
+
var code = await runDispatchCli(Bun.argv.slice(2), process.env, {
|
|
19261
|
+
stdout: writeTo(process.stdout),
|
|
19262
|
+
stderr: writeTo(process.stderr),
|
|
19257
19263
|
readText,
|
|
19258
19264
|
cwd: process.cwd()
|
|
19259
|
-
})
|
|
19265
|
+
});
|
|
19266
|
+
await Promise.all(pending);
|
|
19267
|
+
process.exit(code);
|