From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19049 invoked from network); 6 Sep 2000 13:05:41 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 6 Sep 2000 13:05:41 -0000 Received: (qmail 10085 invoked by alias); 6 Sep 2000 13:05:32 -0000 Mailing-List: contact zsh-workers-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 12755 Received: (qmail 10071 invoked from network); 6 Sep 2000 13:05:31 -0000 X-Envelope-Sender-Is: Andrej.Borsenkow@mow.siemens.ru (at relayer david.siemens.de) From: "Andrej Borsenkow" To: Subject: RE: When should interactive option be set/.zshrc read? Date: Wed, 6 Sep 2000 17:05:27 +0400 Message-ID: <000701c01803$20bcb360$21c9ca95@mow.siemens.ru> MIME-Version: 1.0 Content-Type: text/plain; charset="koi8-r" Content-Transfer-Encoding: 7bit X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.2416 (9.0.2911.0) X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4133.2400 Importance: Normal In-Reply-To: <200009061249.OAA01000@beta.informatik.hu-berlin.de> > Andrej Borsenkow wrote: > > > I was sure, that my .zshrc was read only by interactice zsh, but > > > > bor@itsrm2% print $options[interactive] > > on <= correct > > bor@itsrm2% : | (print $options[interactive]) > > on <= ?? I doubt, this shell can be considered "interactive" > > It's a copy of the interactive shell, a subshell. It doesn't read any > init files whatsoever. > Um, really. Which is even worse. > Hm, but maybe we should turn off the option in subshells. (And probably > other options, too?) > > Non-interactive shells do things like running shell scripts (`#!.../zsh'). > By definition, INTERACTIVE is set "if the standard input is a tty and commands are being read from standard input". In the above case standard input is not tty and commands are not being read from standard input. Well, I am concerned now how to prevent all definitions from .zshrc to be used in subshell. I definitely do not want that (ls foo| ...) use my alias for ls; and I do not want window title be mangled. Any idea? Is it possible to provide "clean sandbox" for subshells? -andrej