From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 17043 invoked from network); 30 Jul 2008 13:14:03 -0000 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00 autolearn=ham version=3.2.5 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 30 Jul 2008 13:14:03 -0000 Received-SPF: none (ns1.primenet.com.au: domain at sunsite.dk does not designate permitted sender hosts) Received: (qmail 14539 invoked from network); 30 Jul 2008 13:13:59 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 30 Jul 2008 13:13:59 -0000 Received: (qmail 5318 invoked by alias); 30 Jul 2008 13:13:57 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 25354 Received: (qmail 5300 invoked from network); 30 Jul 2008 13:13:56 -0000 Received: from bifrost.dotsrc.org (130.225.254.106) by sunsite.dk with SMTP; 30 Jul 2008 13:13:56 -0000 Received: from eris.feh.name (eris.feh.name [88.198.13.233]) by bifrost.dotsrc.org (Postfix) with ESMTP id 7FCF2802A5D4 for ; Wed, 30 Jul 2008 15:13:39 +0200 (CEST) Received: by eris.feh.name (Postfix, from userid 1000) id 3ADCDF61510; Wed, 30 Jul 2008 15:13:39 +0200 (CEST) Date: Wed, 30 Jul 2008 15:13:39 +0200 From: Julius Plenz To: zsh-workers@sunsite.dk Subject: completion functions with _arguments -A "-*" and the _approximate completer Message-ID: <20080730131339.GC1113@plenz.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline X-PGP-Key: 0x186DCA0D X-URL: http://www.plenz.com/ X-Editor: Vim 7.0 - set ai et ts=4 tw=70 comments=b:#,:%,fb:-,n:>,n:) nosm nonu User-Agent: Mutt/1.5.13 (2006-08-11) X-Virus-Scanned: ClamAV version 0.92.1, clamav-milter version 0.92.1 on bifrost X-Virus-Status: Clean Hi folks! I noticed that a few completion functions don't work work together with the _approximate completer properly, namely all functions that contain the argument '-A "-*"' in the _arguments command, like _gpg does, for example. Usual behaviour is this: zsh> gpg --alwasy no more arguments If I remove the -A part, approximation works as expected: zsh> gpg --alwasy zsh> gpg --always-trust The manual states: ``For example, to make _arguments stop completing options after the first normal argument, but ignoring all strings starting with a hyphen even if they are not described by one of the optspecs, the form is `-A "-*"'.'' But shouldn't _arguments give _approximate a chance to complete an option name that was just mis-spelled? IMO this breaks consitency because you cannot rely on _approximate correcting the option name. Or am I wrong here? Julius