From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 18316 invoked by alias); 26 Jan 2011 14:27:03 -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: 28658 Received: (qmail 12043 invoked from network); 26 Jan 2011 14:27:01 -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=-2.7 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW, T_TO_NO_BRKTS_FREEMAIL autolearn=ham version=3.3.1 Received-SPF: pass (ns1.primenet.com.au: SPF record at _spf.google.com designates 209.85.216.178 as permitted sender) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:from:date :message-id:subject:to:content-type; bh=ASGGCLZ4PxOFl4ebX6CBmDhjWdMBKCY8g0ky8k7KPr0=; b=n7wCAVS+M+uGRureQox69dbfuFMisYwuAb6JbPuLew/US3oVLU6ue+zpFJG+JkmN/v IUlvrQ0/M1NKeH65xjiIcKGKbXgf10uLx6ePC/8WAvL8o8QSp1aM95UicoNUY555YUld UVmimM/RJrHxJvtTuPAIXQfqQDET6iujNN11s= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :content-type; b=r+DVX9wdNMqCUMaSAlcvpCFMxCAKVhGNlb9+RNEq+UjXcl3dozIDLfamUX2J95ertd YP1DtuYlbvM501wMnv4vS3V4PSTSvuS7TtXTZRqk/adTFvsR50vZQ431TaF8k+VaPBGN 6bw4t96oMqX18mDBk9vVleIBQ0+EkWiZy7aco= MIME-Version: 1.0 In-Reply-To: <87oc74dpuy.fsf@ft.bewatermyfriend.org> References: <87oc74dpuy.fsf@ft.bewatermyfriend.org> From: cheer_xiao Date: Wed, 26 Jan 2011 22:21:18 +0800 Message-ID: Subject: Re: Slow completion when using aptitude To: zsh-workers@zsh.org Content-Type: text/plain; charset=UTF-8 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. It seems that I have done nothing special about them, and the following is a snippet of my .zshrc: # The following lines were added by compinstall zstyle ':completion:*' file-sort name zstyle ':completion:*' list-colors ${(s.:.)LS_COLORS} zstyle ':completion:*' matcher-list 'm:{[:lower:]}={[:upper:]}' 'r:|[._-]=* r:|=*' 'l:|=* r:|=*' zstyle ':completion:*' menu select=1 zstyle ':completion:*' select-prompt '%SScrolling active: current selection at %p%s' zstyle :compinstall filename '/home/xiaq/.zshrc' autoload -Uz compinit compinit # End of lines added by compinstall # Lines configured by zsh-newuser-install To make things more clear, I tried the following: xiaq@~> zsh -f xiaq@~> autoload -Uz compinit && compinit to get a minimal zsh environment with tab-completion enabled. The result is still the same. > [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. I did install the version from Ubuntu repo, but now I have already removed it. xiaq@~> which -a zsh /usr/local/bin/zsh Could you check whether "aptitude -h" on your system mentions build-dep? That of my system (Ubuntu 10.04) doesn't; while apt-get does: 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.)