From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 15881 invoked by alias); 26 Jan 2011 15:18:58 -0000 Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Workers List List-Post: List-Help: X-Seq: 28659 Received: (qmail 29301 invoked from network); 26 Jan 2011 15:18:46 -0000 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_NONE, SPF_HELO_PASS autolearn=ham version=3.3.1 Received-SPF: none (ns1.primenet.com.au: domain at bewatermyfriend.org does not designate permitted sender hosts) From: Frank Terbeck To: cheer_xiao Cc: zsh-workers@zsh.org Subject: Re: Slow completion when using aptitude In-Reply-To: (cheer xiao's message of "Wed, 26 Jan 2011 22:21:18 +0800") References: <87oc74dpuy.fsf@ft.bewatermyfriend.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (gnu/linux) Date: Wed, 26 Jan 2011 15:55:26 +0100 Message-ID: <87d3njemu9.fsf@ft.bewatermyfriend.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Df-Sender: 430444 cheer_xiao wrote: > On Wed, Jan 26, 2011 at 4:35 PM, Frank Terbeck wrote: >> [snip] >> _aptitude does more than _apt-get. If the second doesn't take as >> long as the first, you probably got caching enabled via zstyle. > > So the problem is, as I understand, the cache for apt-get is > persistent, while that of aptitude isn't. [...] The difference is, that "aptitude install " lists uninstalled packages, whereas "apt-get install " simply lists all available packages. The former, while being more appropriate, also takes more work. I must admit, that I'm not quite familiar with how compsys' caching is implemented. I may be giving wrong pointers here. So I should better be quiet. >> [snip] >> Are you sure you don't have two competing versions of zsh installed? >> Then it may be possible that "print $ZSH_VERSION" and "zsh --version" >> would yield different results. [...] > xiaq@~> aptitude -h | grep build > [no result] > xiaq@~> apt-get | grep build > build-dep - Configure build-dependencies for source packages > > > I doubt whether zsh's tab-completion of aptitude's(and other > utilities') verbs works by looking at "aptitude -h" first to generate > the verbs list. If so, the problem should be considered a bug of > aptitude that ships with Ubuntu 10.04 instead of zsh. (This has been > confirmed, so this minor bug belongs to aptitude instead of zsh.) The aptitude completion *does* in fact look at "aptitude -h" to figure out which sub-commands to offer. And my aptitude does include it in its output. Are you sure that your aptitude supports `build-dep'? Because its author claims the help message was updated the in the same version the functionality was added: (Although I think I remember an aptitude that had `build-dep' and didn't list it in -h output. But I'm not sure.) Regards, Frank -- In protocol design, perfection has been reached not when there is nothing left to add, but when there is nothing left to take away. -- RFC 1925