From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 25276 invoked from network); 23 Apr 2006 15:30:46 -0000 X-Spam-Checker-Version: SpamAssassin 3.1.1 (2006-03-10) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.5 required=5.0 tests=AWL,BAYES_00, FORGED_RCVD_HELO autolearn=ham version=3.1.1 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 23 Apr 2006 15:30:46 -0000 Received: (qmail 65290 invoked from network); 23 Apr 2006 15:30:37 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 23 Apr 2006 15:30:37 -0000 Received: (qmail 24176 invoked by alias); 23 Apr 2006 15:30:30 -0000 Mailing-List: contact zsh-users-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 10169 Received: (qmail 24167 invoked from network); 23 Apr 2006 15:30:30 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by sunsite.dk with SMTP; 23 Apr 2006 15:30:30 -0000 Received: (qmail 64316 invoked from network); 23 Apr 2006 15:30:30 -0000 Received: from acolyte.scowler.net (216.254.112.45) by a.mx.sunsite.dk with SMTP; 23 Apr 2006 15:30:28 -0000 Received: by acolyte.scowler.net (Postfix, from userid 1000) id F227770055; Sun, 23 Apr 2006 11:30:26 -0400 (EDT) Date: Sun, 23 Apr 2006 11:30:26 -0400 From: Clint Adams To: Zsh User Subject: Re: [patch] _aptitude Message-ID: <20060423153026.GA21231@scowler.net> Mail-Followup-To: Zsh User References: <20060420102032.GA30065@let.rug.nl> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20060420102032.GA30065@let.rug.nl> User-Agent: Mutt/1.5.11+cvs20060403 > I started using aptitude recently and noticed that the completion for > some commands were not behaving as expected, so I made some trivial > changes to the _aptitude file. Thanks. Your changes have been incorporated for the next release. > Note that (un)markauto are meant to be used on *installed* packages, > and so I moved them into the appropriated group. Ideally they should > complete on "unmarked/marked" packages, the list of marked packages is > available through > > aptitude -F"%p" search \~M > but (i) that's a bit slow and (ii) I couldn't figure a way to include > this in the completion function (in the 5min I spent trying that is...) Since that takes so long, you should probably make use of the caching layer; search for _cache in the zshcompsys man page or look at _deb_packages. To include it without any caching, you can replace your invocation of _deb_packages with something like this: _wanted package expl 'package' compadd $(aptitude -F"%p" search \~M) > I reckon that some options I just turned ON allow things like > packagename=version and that is not being done, yet "aptitude install" > also allows for things like "~nzsh" and that's not implemented either; > so I concluded that it was OK to do it so. packagename=version and packagename/suite would be nice additions as well.