Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: stdbuf -o0 -i0 via a Zsh native interface?



On Thu, May 25, 2023 at 7:16 AM Peter Stephenson
<p.w.stephenson@xxxxxxxxxxxx> wrote:
>
> > On 25/05/2023 12:21 Sebastian Gniazdowski <sgniazdowski@xxxxxxxxx> wrote:
> > However, this is sub-optimal solution because I have to hideously
> > prepend the stdbuf command before each user CMD, meaning that entering
> > builtin commands will not work (e.g.: `stdbuf -i0 -o0 print smthg`).
> >
> > I wonder if the infamous buffering problem, solved by the hacky
> > ld-preload stdbuf program could be fixed on the level of Zsh?
>
> Something like this?  It looks like a good fit for zsystem.

That's a start, but it doesn't solve Sebastian's problem of having to
hack the stdbuf prefix into the command string for external commands.

We'd need something akin to the STTY parameter to specify a prefix for
external commands.  That might have its own security concerns.




Messages sorted by: Reverse Date, Date, Thread, Author