On Dez 09 2024, Mike Jonkmans wrote: > So, with 'if false; then :; fi', the whole if has 0 as status, due to #1. > The last pipeline is the 'false' command. So $PIPESTATUS = 1.
Why is `if false; then :; fi' not a pipeline? It is a command, and the components of a pipeline are commands. > Both other examples, e.g. 'if false; then :; fi | true', > are, for PIPESTATUS purposes, equivalent to: 'true | true'. Why is `if false; then :; fi' not equivalent to `true' above? -- Andreas Schwab, sch...@linux-m68k.org GPG Key fingerprint = 7578 EB47 D4E5 4D69 2510 2552 DF73 E780 A9DA AEC1 "And now for something completely different."