From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 4509 invoked from network); 1 Aug 2006 20:19:05 -0000 X-Spam-Checker-Version: SpamAssassin 3.1.4 (2006-07-25) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.4 required=5.0 tests=AWL,BAYES_00, FORGED_RCVD_HELO,SUBJ_HAS_UNIQ_ID autolearn=ham version=3.1.4 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 1 Aug 2006 20:19:05 -0000 Received-SPF: none (ns1.primenet.com.au: domain at sunsite.dk does not designate permitted sender hosts) Received: (qmail 92072 invoked from network); 1 Aug 2006 20:18:54 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 1 Aug 2006 20:18:54 -0000 Received: (qmail 9055 invoked by alias); 1 Aug 2006 20:18:52 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 22574 Received: (qmail 9045 invoked from network); 1 Aug 2006 20:18:52 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by sunsite.dk with SMTP; 1 Aug 2006 20:18:52 -0000 Received: (qmail 91815 invoked from network); 1 Aug 2006 20:18:52 -0000 Received: from mta08-winn.ispmail.ntl.com (HELO mtaout02-winn.ispmail.ntl.com) (81.103.221.48) by a.mx.sunsite.dk with SMTP; 1 Aug 2006 20:18:50 -0000 Received: from aamtaout02-winn.ispmail.ntl.com ([81.103.221.35]) by mtaout02-winn.ispmail.ntl.com with ESMTP id <20060801201849.TIPN27023.mtaout02-winn.ispmail.ntl.com@aamtaout02-winn.ispmail.ntl.com> for ; Tue, 1 Aug 2006 21:18:49 +0100 Received: from pwslaptop.csr.com ([81.107.41.155]) by aamtaout02-winn.ispmail.ntl.com with ESMTP id <20060801201849.NHLH23938.aamtaout02-winn.ispmail.ntl.com@pwslaptop.csr.com> for ; Tue, 1 Aug 2006 21:18:49 +0100 Received: from pwslaptop.csr.com (pwslaptop.csr.com [127.0.0.1]) by pwslaptop.csr.com (8.13.7/8.13.7) with ESMTP id k71KIkQK002718 for ; Tue, 1 Aug 2006 21:18:46 +0100 Message-Id: <200608012018.k71KIkQK002718@pwslaptop.csr.com> From: Peter Stephenson To: zsh-workers@sunsite.dk (Zsh hackers list) Subject: Re: Menu-driven version of history-beginning-search-backward In-Reply-To: Message from Peter Stephenson of "Tue, 01 Aug 2006 18:30:31 BST." <200608011730.k71HUWJT031570@news01.csr.com> Date: Tue, 01 Aug 2006 21:18:46 +0100 I suppose this is going to come to an end soon. It must be nice being smart. Index: Doc/Zsh/params.yo =================================================================== RCS file: /cvsroot/zsh/zsh/Doc/Zsh/params.yo,v retrieving revision 1.30 diff -u -r1.30 params.yo --- Doc/Zsh/params.yo 1 Aug 2006 17:35:17 -0000 1.30 +++ Doc/Zsh/params.yo 1 Aug 2006 20:17:51 -0000 @@ -221,7 +221,7 @@ match an element of an array tt($array) containing exactly the value of tt($key): -example(key2=${key//(#m)[\][+LPAR()+RPAR()\\*?#<>]/\\$MATCH} +example(key2=${key//(#m)[\][+LPAR()+RPAR()\\*?#<>~]/\\$MATCH} print ${array[(R)$key2]}) ) item(tt(R))( Index: Functions/Zle/history-beginning-search-menu =================================================================== RCS file: /cvsroot/zsh/zsh/Functions/Zle/history-beginning-search-menu,v retrieving revision 1.3 diff -u -r1.3 history-beginning-search-menu --- Functions/Zle/history-beginning-search-menu 1 Aug 2006 17:35:18 -0000 1.3 +++ Functions/Zle/history-beginning-search-menu 1 Aug 2006 20:17:51 -0000 @@ -40,12 +40,12 @@ local search=$LBUFFER +search=${search//(#m)[\][()\\*?#<>~]/\\$MATCH/} if [[ $WIDGET = *-space* ]]; then # We need to quote metacharacters in the search string # since they are otherwise active in the reverse subscript. # We need to avoid quoting other characters since they aren't # and just stay quoted, rather annoyingly. - search=${search//(#m)[\][()\\*?#<>]/\\$MATCH/} search=${search// /*} fi @@ -112,7 +112,7 @@ # go to the last one. This allows accept-line-and-down-history etc. # to work. local -a lines -local matchq=${matches[$chars]//(#m)[\][()\\*?#<>]/\\$MATCH} +local matchq=${matches[$chars]//(#m)[\][()\\*?#<>~]/\\$MATCH} lines=(${(kon)history[(R)$matchq]}) HISTNO=$lines[-1] -- Peter Stephenson Web page now at http://homepage.ntlworld.com/p.w.stephenson/