From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24611 invoked from network); 10 Feb 2000 14:10:27 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 10 Feb 2000 14:10:27 -0000 Received: (qmail 6146 invoked by alias); 10 Feb 2000 14:10:09 -0000 Mailing-List: contact zsh-workers-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 9658 Received: (qmail 6052 invoked from network); 10 Feb 2000 14:10:03 -0000 Date: Thu, 10 Feb 2000 15:10:01 +0100 (MET) Message-Id: <200002101410.PAA25260@beta.informatik.hu-berlin.de> From: Sven Wischnowsky To: zsh-workers@sunsite.auc.dk In-reply-to: Oliver Kiddle's message of Thu, 10 Feb 2000 12:58:19 +0000 Subject: Re: PATCH: _diff Oliver Kiddle wrote: > This may have already been fixed but the diff completion seemed to call > diff with /dev/null as stdin but not stdout and stderr. This causes me > to get an error messages about -v not being an option in the middle of > my command line. I take it that redirecting stdin was a typo? > > I seem to remember a recent discussion which I didn't follow fully about > how to call programs from completion functions and a proposed > configurable function for doing it so I haven't patched the use of > 'command diff'. I leave the original diff and link GNU diff to 'gdiff'. > With the current _diff, I can't then get GNU style completion for gdiff. > Having both the GNU and supplied utilites are fairly common place on > commercial UNIX installations. For this reason, I object to using > non-local variables like _diff_is_gnu and calling 'diff' instead of > pulling out the first word on the command-line. Well, if we use something like _diff_is_gnu[$words[1]], using a non-local variable should be fine, right? But you are right -- I had forgotten to integrate using $words[1] into my suggestion somehow. Hm. Still no patch for any of this, though. The problem is that this would probably be interesting in several places so that updating the docs would be quite a bit of work. And since we also had the `discussion' about trying to add some auto-documentation mechanism (using magic comments in the functions) I wanted to delay it until we had thought about that some more. Bye Sven -- Sven Wischnowsky wischnow@informatik.hu-berlin.de