From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 16818 invoked from network); 25 Aug 1999 15:49:23 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 25 Aug 1999 15:49:23 -0000 Received: (qmail 7624 invoked by alias); 25 Aug 1999 15:49:04 -0000 Mailing-List: contact zsh-users-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 2513 Received: (qmail 7615 invoked from network); 25 Aug 1999 15:49:00 -0000 Sender: jrh@evermore.vicor-nb.com To: zsh-users@sunsite.auc.dk Subject: Perl like select()? From: Josh Howard Date: 25 Aug 1999 08:48:09 -0700 Message-ID: <87so57dfpi.fsf@evermore.vicor-nb.com> User-Agent: Gnus/5.070095 (Pterodactyl Gnus v0.95) XEmacs/20.4 (Emerald) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Is there any way, in a script, to use a "Perl-like" select() to associate stdout with a particular file, before the execution of the rest of the script? For instance: I have a shell script that I want to simply put ">log.file" at the top, and then start echo'ing and doing various output and expect everything to go to log.file, as opposed to doing something like "./script.sh >> log.file" In perl, you can open() and select() a file to associate where stdout is written to. This might be a useful feature in zsh if it doesn't already exist. -- Josh Howard