How can I progressively iterate over stdout lines with a custom delimiter
I am attempting to monitor progress of `HandBrakeCLI`, which outputs its progress delimited by `\r` instead of `\n`. Is there a way that I can choose a custom delimiter when [progressively iterating](https://github.com/sindresorhus/execa/blob/main/docs/lines.md#progressive-splitting) over the process's `stdout`?
I am unable to find any docs on this, and the quick test I threw together seems to indicate that it is not easily possible.
Currently, my workaround is to pipe the output through `tr '\r', '\n'`, but being able to do this directly with `execa` would make things much simpler.
4 条评论