From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19224 invoked from network); 23 Dec 2002 01:29:00 -0000 Received: from sunsite.dk (130.225.247.90) by ns1.primenet.com.au with SMTP; 23 Dec 2002 01:29:00 -0000 Received: (qmail 134 invoked by alias); 23 Dec 2002 01:28:50 -0000 Mailing-List: contact zsh-users-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 5603 Received: (qmail 120 invoked from network); 23 Dec 2002 01:28:49 -0000 From: "Bart Schaefer" Message-Id: <1021223012821.ZM13386@candle.brasslantern.com> Date: Mon, 23 Dec 2002 01:28:21 +0000 In-Reply-To: <20021221203256.3445250b.david@eelf.ddts.net> Comments: In reply to David B Harris "The removal of spaces after a tab-complete" (Dec 21, 8:32pm) References: <20021221203256.3445250b.david@eelf.ddts.net> X-Mailer: Z-Mail (5.0.0 30July97) To: zsh-users@sunsite.dk Subject: Re: The removal of spaces after a tab-complete MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii On Dec 21, 8:32pm, David B Harris wrote: } } I'm finding some irritating behaviour with zsh that I can't seem to turn } off. Specifically, after I make a completion, then hit "|" (that's a } pipe), zsh deletes the space that was inserted after the tab-complete. You can't turn it off. You can only forcibly defeat it. You can either define your own completions with auto-suffix-removal disabled, for every situation in which you don't want this to happen; or you can re-bind the specific keys for which, when typed after a completion, it should not happen. The latter is probably easier: function self-insert-no-autoremove { LBUFFER="$LBUFFER$KEYS" } zle -N self-insert-no-autoremove bindkey '|' self-insert-no-autoremove The reasons why you can't turn it off are varied and in some instances nearly lost in the mists of time, but it boils down to something like: (1) it was automatically added, so it's not costing you keystrokes if it automatically goes away again; (2) the absence of the space doesn't matter to the syntax; (3) there are more cases where leaving the space is wrong, than cases where removing it is wrong; so (4) if you really want a space there, you can just type one yourself.