From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21095 invoked from network); 11 Oct 1999 10:45:55 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 11 Oct 1999 10:45:55 -0000 Received: (qmail 20159 invoked by alias); 11 Oct 1999 10:45:19 -0000 Mailing-List: contact zsh-users-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 2665 Received: (qmail 20152 invoked from network); 11 Oct 1999 10:45:18 -0000 Date: Mon, 11 Oct 1999 12:45:16 +0200 (MET DST) Message-Id: <199910111045.MAA03145@beta.informatik.hu-berlin.de> From: Sven Wischnowsky To: zsh-users@sunsite.auc.dk In-reply-to: Chris Hansen's message of Sun, 3 Oct 1999 22:21:16 -0700 (MST) Subject: Re: coproc tutorial (Re: questions) Chris Hansen wrote: > #!/bin/zsh -i > > coproc /usr/bin/nslookup > > while true; do > TEST=">" > NSLOUT=" " > while [[ $TEST != $NSLOUT ]] ; do > print -n $NSLOUT > read -pk NSLOUT > done > read 'QUERY?>' > print -p $QUERY > done 3.1.6-pws-something (at least the latest pws-6) has Functions/Misc/nslookup which uses `vared' to read the user input, thus allowing command line editing. Together with the new completion system this function will also give you completion *inside* nslookup (and not only nslookup's arguments). To workers: seems like noone found this interesting enough to improve the code I hacked up. Maybe sometime we could write a generic function for this task... Bye Sven -- Sven Wischnowsky wischnow@informatik.hu-berlin.de