From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 10461 invoked from network); 5 Apr 2004 19:01:22 -0000 Received: from sunsite.dk (130.225.247.90) by ns1.primenet.com.au with SMTP; 5 Apr 2004 19:01:22 -0000 Received: (qmail 11612 invoked by alias); 5 Apr 2004 19:00:52 -0000 Mailing-List: contact zsh-users-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 7328 Received: (qmail 11573 invoked from network); 5 Apr 2004 19:00:52 -0000 Received: from localhost (HELO sunsite.dk) (127.0.0.1) by localhost with SMTP; 5 Apr 2004 19:00:52 -0000 X-MessageWall-Score: 0 (sunsite.dk) Received: from [130.225.247.86] by sunsite.dk (MessageWall 1.0.8) with SMTP; 5 Apr 2004 19:0:52 -0000 Received: (qmail 30423 invoked from network); 5 Apr 2004 19:00:51 -0000 Received: from mail36.messagelabs.com (193.109.254.211) by a.mx.sunsite.dk with SMTP; 5 Apr 2004 19:00:45 -0000 X-VirusChecked: Checked X-Env-Sender: okiddle@yahoo.co.uk X-Msg-Ref: server-7.tower-36.messagelabs.com!1081191617!5222009 X-StarScan-Version: 5.2.10; banners=-,-,- X-Originating-IP: [158.234.9.163] Received: (qmail 23575 invoked from network); 5 Apr 2004 19:00:17 -0000 Received: from iris.logica.co.uk (158.234.9.163) by server-7.tower-36.messagelabs.com with SMTP; 5 Apr 2004 19:00:17 -0000 Received: from trentino.logica.co.uk ([158.234.142.61]) by iris.logica.co.uk (8.12.3/8.12.3/Debian -4) with ESMTP id i35J0GMO018952; Mon, 5 Apr 2004 20:00:16 +0100 Received: from trentino.logica.co.uk (localhost [127.0.0.1]) by trentino.logica.co.uk (Postfix) with ESMTP id 7302178590F1; Mon, 5 Apr 2004 20:59:32 +0200 (CEST) Cc: zsh-users@sunsite.dk X-VirusChecked: Checked X-StarScan-Version: 5.0.7; banners=.,-,- In-reply-to: <1gyr312onv6xj$.dlg@thorstenkampe.de> From: Oliver Kiddle References: <1gyr312onv6xj$.dlg@thorstenkampe.de> To: Thorsten Kampe Subject: Re: .zshrc sanity check Date: Mon, 05 Apr 2004 20:59:32 +0200 Message-ID: <17660.1081191572@trentino.logica.co.uk> X-Spam-Checker-Version: SpamAssassin 2.63 on a.mx.sunsite.dk X-Spam-Level: X-Spam-Status: No, hits=0.0 required=6.0 tests=none autolearn=no version=2.63 X-Spam-Hits: 0.0 Thorsten Kampe wrote: > > re-reading the User's guide I have made many changes to my .zshrc and > zstyle ':completion:*' completer _expand _complete _match _approximate _ignored > zstyle ':completion:*:expand:*' glob true The _match completer is pretty much superfluous if you already use _expand to expand any globs. I have _match bound to a separate key. > zstyle ':completion:*:approximate:*' insert-unambiguous true This style is not doing anything. _approximate only looks up that style after it has added the number of corrections to the context. I use: zstyle ':completion::approximate*:*' insert-unambiguous true > zstyle ':completion:*:approximate:*' original false false is the default value for this style. It would also need an extra `*' in the style after `approximate'. If you never want _approximate to add the original string as a match, you need to use: zstyle ':completion::approximate:*' tag-order corrections You might want to think about using more specific contexts for quite a few of the styles. It is worth thinking through all the style components whenever you set a style. If you can't remember the components, add a comment: # contexts are :completion::::: I prefer to avoid matching anything (with *) in the function component with styles that affect completion behaviour. Another case where you could make the context more specific: > zstyle ':completion:*:functions' ignored-patterns '_*' Anything which restricts matches by literal checks of what has already been typed against a fixed string tends not to be desirable for the _correct and _approximate completers. This is because you might mis-type the literal string. So, for example: unfunction -ssh won't correct to unfunction _ssh I instead use: zstyle ':completion::(^approximate*):*:functions' ignored-patterns '_*' > zstyle ':completion:*:expand:*' subst-globs-only true You might want to rethink setting that (and your expand styles in general since it looks like you've just set everything true). Other styles now do a better job with what I tried to do with subst-globs-only. Other than that, it rest comes down to personal preference. I found myself thinking "yuk" but not "that's insane" on seeing some of your option settings. A couple of options you may want to try setting are c_bases and braceccl. Oliver