Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/18/84; site brl-tgr.ARPA Path: utzoo!watmath!clyde!bonnie!akgua!sdcsvax!sdcrdcf!hplabs!hao!seismo!brl-tgr!gwyn From: gwyn@brl-tgr.ARPA (Doug Gwyn) Newsgroups: net.unix-wizards Subject: Re: How should command substitution (`...`) work? Message-ID: <6267@brl-tgr.ARPA> Date: Sat, 1-Dec-84 02:03:56 EST Article-I.D.: brl-tgr.6267 Posted: Sat Dec 1 02:03:56 1984 Date-Received: Tue, 4-Dec-84 05:44:52 EST References: <332@stcvax.UUCP> Organization: Ballistic Research Lab Lines: 14 > p `egrep -l pattern *` > It seems more natural to me that the shell should (silently) not > run a pipeline if any command substitutions in it fail. In case the filename matching is a side issue and you are mostly concerned about the shell continuing when the `` command returns a non-zero exit status, I definitely HAVE seen instances where the current behavior is desired. Non-zero exit status is not always a catastrophic failure, as in the case of grep. BRL UNIXes have a ^T "mini-systat" feature that lets one easily determine whether he needs to type something (process shown as blocked awaiting terminal input). This is an ugly but useful hack that makes accidents like the above much easier to cope with.