From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20220 invoked from network); 21 Feb 2004 01:35:32 -0000 Received: from sunsite.dk (130.225.247.90) by ns1.primenet.com.au with SMTP; 21 Feb 2004 01:35:32 -0000 Received: (qmail 23571 invoked by alias); 21 Feb 2004 01:35:20 -0000 Mailing-List: contact zsh-users-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 7073 Received: (qmail 23558 invoked from network); 21 Feb 2004 01:35:20 -0000 Received: from localhost (HELO sunsite.dk) (127.0.0.1) by localhost with SMTP; 21 Feb 2004 01:35:20 -0000 X-MessageWall-Score: 0 (sunsite.dk) Received: from [80.91.224.249] by sunsite.dk (MessageWall 1.0.8) with SMTP; 21 Feb 2004 1:35:18 -0000 Received: from list by main.gmane.org with local (Exim 3.35 #1 (Debian)) id 1AuM33-0006he-00 for ; Sat, 21 Feb 2004 02:35:17 +0100 Received: from isi-dialin-129-127.isionline-dialin.de ([195.158.129.127]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sat Feb 21 01:35:17 2004 Received: from thorsten by isi-dialin-129-127.isionline-dialin.de with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sat Feb 21 01:35:17 2004 X-Injected-Via-Gmane: http://gmane.org/ To: zsh-users@sunsite.dk From: Thorsten Kampe Subject: Re: incremental history search Date: Sat, 21 Feb 2004 02:35:14 +0100 Message-ID: References: <1lk8q9de9jvbv.dlg@thorstenkampe.de> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Complaints-To: usenet@sea.gmane.org X-Gmane-NNTP-Posting-Host: isi-dialin-129-127.isionline-dialin.de User-Agent: 40tude_Dialog/2.0.10.1de Sender: news * Eric Mangold (2004-02-21 02:17 +0100) > On Sat, 21 Feb 2004 00:04:00 +0100, Thorsten Kampe > wrote: >> I have bound[1] the cursor keys to "up-line-or-search" and >> down-line-or-search. Unfortunately this only completes the first word >> of the search; meaning when I type >> >> wget http://foo.com >> wget ftp://bar.com >> >> and then... >> wget http[up cursor] >> ...it completes to "wget ftp://bar.com" and not to the desired "wget >> http://foo.com". It only searches matches for the first word ("wget") >> of the already typed command line in history. >> >> Is it possible to make zsh search for matches of the whole command >> line ("wget http") - and not only the first word? > > Yes. I use the following bindings for that. > > bindkey '\M-p' history-beginning-search-backward > bindkey '\M-n' history-beginning-search-forward Aah, seems like exactly what I want. Are there any functional disadvantages compared to "up-line-or-search"/"down-line-or-search" (because it seems to me as "history-beginning-search-backward" is a superset of "up-line-or-search")? Thorsten