[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: pipefail option doesn't work as advertised
From: |
Tim Waugh |
Subject: |
Re: pipefail option doesn't work as advertised |
Date: |
Wed, 18 Aug 2004 14:44:15 +0100 |
User-agent: |
Mutt/1.4.1i |
On Wed, Aug 18, 2004 at 02:32:52PM +0100, ben@ncipher.com wrote:
> When using the pipefail option, the following command:
> echo foo | false
> produces an exit status of 0, ignoring the exit status of false.
It works for me. Do you have PROMPT_COMMAND set? If so that will
mess up the exit status.
[tim@cyberelk ~]$ unset PROMPT_COMMAND
[tim@cyberelk ~]$ echo foo | false
[tim@cyberelk ~]$ echo $?
1
[tim@cyberelk ~]$
GNU bash, version 3.00.0(1)-release (i386-redhat-linux-gnu)
Tim.
*/
pgpojgBT0C4kV.pgp
Description: PGP signature