On Sat, 21 Jan 2023 20:30:09 -0600
Peng Yu <pengyu.ut@gmail.com> wrote:
> Hi,
>
> The return status of the sourced unnamed pipe is not available. What
> is the best way to catch the return status of the unnamed pipe?
> Thanks.
>
> source <(false) || echo "$?"
$ : <(false); wait $!; echo $?
1
Quoting the bash-4.4-alpha release notes:
u. Bash now allows waiting for the most recent process substitution, since it
appears as $!.
--
Kerin Millar