From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 14908 invoked from network); 7 Jun 2000 14:44:12 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 7 Jun 2000 14:44:12 -0000 Received: (qmail 8969 invoked by alias); 7 Jun 2000 14:44:06 -0000 Mailing-List: contact zsh-workers-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 11797 Received: (qmail 8960 invoked from network); 7 Jun 2000 14:44:03 -0000 From: "Bart Schaefer" Message-Id: <1000607144208.ZM8052@candle.brasslantern.com> Date: Wed, 7 Jun 2000 14:42:08 +0000 In-Reply-To: <200006070649.IAA11929@beta.informatik.hu-berlin.de> Comments: In reply to Sven Wischnowsky "Re: blah*[TAB] (difference between 3.1.6 and 3.1.9)" (Jun 7, 8:49am) References: <200006070649.IAA11929@beta.informatik.hu-berlin.de> X-Mailer: Z-Mail (5.0.0 30July97) To: Sven Wischnowsky , zsh-workers@sunsite.auc.dk Subject: Re: blah*[TAB] (difference between 3.1.6 and 3.1.9) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii On Jun 7, 8:49am, Sven Wischnowsky wrote: } Subject: Re: blah*[TAB] (difference between 3.1.6 and 3.1.9) } } I wrote: } } > Bart Schaefer wrote: } > } > > Something's definitely gone wrong with expand-or-complete. This was not } > > intentional. } > } > Ahem. Changed in 9777 in reply to 9756 (guess the author). } > } > 9777 commented out some stuff in doexpansion(). Change it back? } } I want to get that from my todo-list. Should we change it back? Bart } (9765 was from you)? Sorry, I couldn't make up my mind yesterday. In 9777 you wrote: > About the space: this was obviously intentional, too. I've just > changed the test in doexpansion() so we can go back easily if suddenly > we decide the old behaviour was better. But what I would really like > to have is a better test: when do we want the space and when not. I think it should add the space only when the expansion results in more than one word being inserted. The reasoning is that it probably doesn't make sense to continue completing only the last of several words that were generated from the same pattern, but if only one word resulted then it might reasonably be a prefix of a longer completion. The potential issue I see with this is that what a lot of people want is really expand-AND-complete (not "or"), which makes them think a space should be appended if the result is an existing plain file, or something like that. In fact, I used to be one of them; for a long time I had "setopt recexact" just so that two tabs would expand and then insert a space rather than expand and then produce a listing (when one file name is a prefix of another). I've since come to the conclusion that recexact is almost always more trouble than it is worth. However, that doesn't help resolve this ... perhaps another style? -- Bart Schaefer Brass Lantern Enterprises http://www.well.com/user/barts http://www.brasslantern.com Zsh: http://www.zsh.org | PHPerl Project: http://phperl.sourceforge.net