Closed dsherret closed 1 year ago
It should be possible to do something like:
const child = $`echo 1 && sleep 10 && echo 2`.stdout("piped").spawn(); await $`deno eval 'await Deno.stdin.readable.pipeTo(Deno.stdout.writable);'`.stdin(child.stdout());
I think probably the return value of spawn() should instead be a special kind of Promise that has methods like .stdout() and .stderr() on it.
spawn()
.stdout()
.stderr()
I think it's ok that this is a little verbose since this isn't a common scenario.
Implemented in #82 and a higher level pipe method implemented in https://github.com/dsherret/dax/pull/218
pipe
It should be possible to do something like:
I think probably the return value of
spawn()
should instead be a special kind of Promise that has methods like.stdout()
and.stderr()
on it.I think it's ok that this is a little verbose since this isn't a common scenario.