[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: simple function causes BASH to exit when -e in effect
From: |
Kevin Layer |
Subject: |
Re: simple function causes BASH to exit when -e in effect |
Date: |
Sun, 24 Dec 2017 11:53:43 -0800 |
Bob,
'set -e' is a double-edged sword, for sure, but I'm not sure it creates
more problems than it solves. Hidden non-zero exits have wasted far more
time, for me, than this little exercise has.
On Sun, Dec 24, 2017 at 11:45 AM, Bob Proulx <bob@proulx.com> wrote:
> Kevin Layer wrote:
> > It took me hours of work to distill this down from a very large and long
> > running script.
>
> > set -eu
>
> Hours and hours of debug time could be saved if people stopped using
> 'set -e' in their programs. It creates more problems than people
> think it solves. Do not meddle in the affairs of 'set -e' for it is
> subtle and quick to anger.
>
> Bob
>