From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 17097 invoked from network); 10 Jul 2006 14:12:48 -0000 X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.5 required=5.0 tests=AWL,BAYES_00, FORGED_RCVD_HELO autolearn=ham version=3.1.3 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 10 Jul 2006 14:12:48 -0000 Received-SPF: none (ns1.primenet.com.au: domain at sunsite.dk does not designate permitted sender hosts) Received: (qmail 74361 invoked from network); 10 Jul 2006 14:12:41 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 10 Jul 2006 14:12:41 -0000 Received: (qmail 23585 invoked by alias); 10 Jul 2006 14:12:28 -0000 Mailing-List: contact zsh-users-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 10506 Received: (qmail 23575 invoked from network); 10 Jul 2006 14:12:27 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by sunsite.dk with SMTP; 10 Jul 2006 14:12:27 -0000 Received: (qmail 72894 invoked from network); 10 Jul 2006 14:12:27 -0000 Received: from ka.cs.utk.edu (160.36.56.221) by a.mx.sunsite.dk with SMTP; 10 Jul 2006 14:12:26 -0000 Received: from localhost (localhost [127.0.0.1]) by ka.cs.utk.edu (Postfix) with ESMTP id 19C942F1B0 for ; Mon, 10 Jul 2006 10:12:52 -0400 (EDT) X-Virus-Scanned: by amavisd-new with ClamAV and SpamAssasin at cs.utk.edu Received: from ka.cs.utk.edu ([127.0.0.1]) by localhost (ka.cs.utk.edu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id mK1C07m06eF0 for ; Mon, 10 Jul 2006 10:12:49 -0400 (EDT) Received: from namib.cs.utk.edu (namib.cs.utk.edu [160.36.59.92]) by ka.cs.utk.edu (Postfix) with ESMTP id B05AF2F21A for ; Mon, 10 Jul 2006 10:12:49 -0400 (EDT) Received: by namib.cs.utk.edu (Postfix, from userid 10605) id 9077636F03; Mon, 10 Jul 2006 10:12:20 -0400 (EDT) Date: Mon, 10 Jul 2006 10:12:20 -0400 From: Chris Johnson To: zsh-users@sunsite.dk Subject: Re: Redirection Symbol After Completion Message-ID: <20060710141220.GA11832@namib.cs.utk.edu> References: <200607081145.k68BiwEY023823@pwslaptop.csr.com> <060708105612.ZM8718@torch.brasslantern.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <060708105612.ZM8718@torch.brasslantern.com> User-Agent: Mutt/1.5.9i Bart Schaefer sent me the following 1.9K: > } > I personally find commands easier to parse with my eye when the space > } > remains before the redirection symbol: > } > > } > cat file.txt | > } > > } > Is there any way to force this space to persist even if I type a > } > redirection operator? > > self-insert-redir() { > integer l=$#LBUFFER > zle self-insert > (( $l >= $#LBUFFER )) && LBUFFER[-1]=" $LBUFFER[-1]" > } > zle -N self-insert-redir > for op in \| \< \> \& > do bindkey "$op" self-insert-redir > done > > I like that so much I might even keep it. I like it too. Thanks so much, Bart! -- Chris Johnson cjohnson@cs.utk.edu http://www.cs.utk.edu/~cjohnson