cd failure killing script [Re: Interactive 2.2 File zapper]

Chip Salzenberg chip at tct.uucp
Sat Aug 18 01:10:43 AEST 1990


[ Discussion cross-posted to gnu.bash.bug. ]

According to les at chinet.chi.il.us (Leslie Mikesell):
>[Bash and ksh] will cause serious problems when executing scripts that are
>perfectly valid for /bin/sh.  They could (should) have required a "set"
>option to be done to make them operate differently.

What an excellent idea!  I intend to change my bash sources to exit on
a failed "cd" unless the shell is interactive or the variable
"no_exit_on_failed_cd" is set.

(Yes, the name is awkward, but it is a logical companion to the
already-implemented "no_exit_on_failed_exec" variable.)
-- 
Chip Salzenberg at Teltronics/TCT     <chip at tct.uucp>, <uunet!pdn!tct!chip>
 "Most of my code is written by myself.  That is why so little gets done."
                 -- Herman "HLLs will never fly" Rubin



More information about the Comp.unix.wizards mailing list