toChunks package:streamly-process

>>> toChunks "echo hello world" & Stdio.putChunks
hello world
Pre-release
The following code is equivalent to the shell command echo "hello world":
>>> :{
Process.toChunks "echo" ["hello world"]
& Stream.fold Stdio.writeChunks
:}
hello world
>>> toChunks = toChunksWith id
Like toChunks but use the specified configuration to run the process.
Like toBytesEither but generates a stream of Array Word8 instead of a stream of Word8.
>>> :{
toChunksEither "bash" ["-c", "echo 'hello'; echo 'world' 1>&2"]
& Stream.fold (Fold.partition Stdio.writeErrChunks Stdio.writeChunks)
:}
world
hello
((),())
>>> toChunksEither = toChunksEitherWith id
Prefer toChunksEither over toBytesEither when performance matters. Pre-release
Like toChunksEither but use the specified configuration to run the process.
Like toChunks but use the specified configuration to run the process.