help-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Not to set PIPESTATUS unless necessary


From: Lawrence Velázquez
Subject: Re: Not to set PIPESTATUS unless necessary
Date: Sun, 19 May 2024 03:25:31 -0400
User-agent: Cyrus-JMAP/3.11.0-alpha0-456-gcd147058c-fm-hotfix-20240509.001-g0aad06e4

On Sat, May 18, 2024, at 11:50 PM, Greg Wooledge wrote:
> Back on topic, a pipeline can be a simple command.
>
> hobbit:~$ help time
> time: time [-p] pipeline
>     Report time consumed by pipeline's execution.
>
> I can run "time sleep 1" without needing to have a | character in the
> pipeline.  Everything in bash and POSIX sh uses this definition.  It's
> 100% consistent.  If you disagree, then you are not using the same
> terminology as the rest of us.

And it's been this way for half a century.  Describing the Thompson
shell in 1973, the fourth edition of the Unix manual said
(https://www.in-ulm.de/~mascheck/bourne/v4/):

        One or more commands separated by `|' or `^' constitute
        a _pipeline_.

Describing the new Bourne shell in 1979, the seventh edition said
(https://www.in-ulm.de/~mascheck/bourne/v7/):

        A _pipeline_ is a sequence of one or more _commands_
        separated by |.

That's at least 51 years of historical convention that you've decided
to flail at with a nontechnical dictionary because you don't want to
use a temporary variable.

-- 
vq



reply via email to

[Prev in Thread] Current Thread [Next in Thread]