From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 17826 invoked from network); 20 Sep 2006 09:15:07 -0000 X-Spam-Checker-Version: SpamAssassin 3.1.5 (2006-08-29) 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 autolearn=ham version=3.1.5 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 20 Sep 2006 09:15:07 -0000 Received-SPF: none (ns1.primenet.com.au: domain at sunsite.dk does not designate permitted sender hosts) Received: (qmail 68078 invoked from network); 20 Sep 2006 09:14:57 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 20 Sep 2006 09:14:57 -0000 Received: (qmail 15968 invoked by alias); 20 Sep 2006 09:14:46 -0000 Mailing-List: contact zsh-users-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 10744 Received: (qmail 15957 invoked from network); 20 Sep 2006 09:14:45 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by sunsite.dk with SMTP; 20 Sep 2006 09:14:45 -0000 Received: (qmail 66650 invoked from network); 20 Sep 2006 09:14:45 -0000 Received: from cluster-d.mailcontrol.com (217.69.20.190) by a.mx.sunsite.dk with SMTP; 20 Sep 2006 09:14:44 -0000 Received: from rly24d.srv.mailcontrol.com (localhost.localdomain [127.0.0.1]) by rly24d.srv.mailcontrol.com (MailControl) with ESMTP id k8K9CoL4013515 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Wed, 20 Sep 2006 10:13:52 +0100 Received: from submission.mailcontrol.com (submission.mailcontrol.com [212.158.48.250]) by rly24d.srv.mailcontrol.com (MailControl) id k8K9CAdU011924 for zsh-users@sunsite.dk; Wed, 20 Sep 2006 10:12:10 +0100 Received: from exchange03.csr.com (uuk202166.uk.customer.alter.net [62.189.241.194]) by rly24d-eth0.srv.mailcontrol.com (envelope-sender Peter.Stephenson@csr.com) (MIMEDefang) with ESMTP id k8K9BWvK010193; Wed, 20 Sep 2006 10:12:09 +0100 (BST) Received: from cameurexb01.EUROPE.ROOT.PRI ([10.100.137.61]) by exchange03.csr.com with Microsoft SMTPSVC(5.0.2195.6713); Wed, 20 Sep 2006 10:10:38 +0100 Received: from news01.csr.com ([10.103.143.38]) by cameurexb01.EUROPE.ROOT.PRI with Microsoft SMTPSVC(6.0.3790.1830); Wed, 20 Sep 2006 10:10:38 +0100 Received: from news01.csr.com (localhost.localdomain [127.0.0.1]) by news01.csr.com (8.13.7/8.13.4) with ESMTP id k8K9AcQP009416; Wed, 20 Sep 2006 10:10:38 +0100 Received: from csr.com (pws@localhost) by news01.csr.com (8.13.7/8.13.7/Submit) with ESMTP id k8K9AbwH009413; Wed, 20 Sep 2006 10:10:38 +0100 Message-Id: <200609200910.k8K9AbwH009413@news01.csr.com> X-Authentication-Warning: news01.csr.com: pws owned process doing -bs To: Roman Neuhauser , zsh-users@sunsite.dk (Zsh users list) Subject: Re: _arguments: repeated option with multiple optargs In-reply-to: <20060919225628.GA46070@dagan.sigpipe.cz> References: <20060919014639.GB29030@dagan.sigpipe.cz> <20060919172825.3f7c6232.pws@csr.com> <20060919225628.GA46070@dagan.sigpipe.cz> Comments: In-reply-to Roman Neuhauser message dated "Tue, 19 Sep 2006 22:56:28 -0000." Date: Wed, 20 Sep 2006 10:10:37 +0100 From: Peter Stephenson X-OriginalArrivalTime: 20 Sep 2006 09:10:38.0453 (UTC) FILETIME=[A3979A50:01C6DC94] Content-Type: text/plain MIME-Version: 1.0 X-Scanned-By: MailControl A-07-04-01 (www.mailcontrol.com) on 10.68.1.134 Roman Neuhauser wrote: > That reminds me: the message part of optarg must not be empty, > otherwise I get no completions, is that a bug? Generally two colons together mean special things. It should work if there's at least a space, otherwise it's certainly a bug. > I looked inside _arguments, it contains (4.2.5) 10 calls to > comparguments, but zsh/computil is basically undocumented with the > excuse that it's "not very interesting" to users. Funny. Yes, that's a real nuisance in working out what's going on. > Thinking some more... In "tence -r file t1 ", _complete_help > says the $context is ":completion::complete:tence::option-r-rest:". > How can I access the value from inside my completion function? I > thought I saw this info somewhere, but cannot find it. I'd like to > see what happens if I change the argument member from option-r-rest > to "" before the call to _arguments, IFF $words[$CURRENT] is "-". You need to manipulate curcontext. The usual idiom is local curcontext="${curcontext}:extra:bits" or something. > BTW, you sent this only to me. Was that intentional? No, I passed on the mail to the list (and this one, too). -- Peter Stephenson Software Engineer CSR PLC, Churchill House, Cambridge Business Park, Cowley Road Cambridge, CB4 0WZ, UK Tel: +44 (0)1223 692070 To access the latest news from CSR copy this link into a web browser: http://www.csr.com/email_sig.php