Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Slow completion
- X-seq: zsh-users 17673
- From: Mikael Magnusson <mikachu@xxxxxxxxx>
- To: Peter Stephenson <p.stephenson@xxxxxxxxxxx>
- Subject: Re: Slow completion
- Date: Thu, 7 Mar 2013 12:44:55 +0100
- Cc: zsh-users@xxxxxxx
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type:content-transfer-encoding; bh=zwJ5njSn6rZZbEPcav0qssf1ZGVgzs+jHxNKd8SqYcw=; b=iiWqr6esOp4yVG3c9tk5OR5wj1OPMJms1aGTQo3z6T0LCo4qKRVLKefLtxaI/o0jYE hVeJKkpaXO2F8c7tUVkEizQz22zBomy+7j0BQFyvfwBZG4M686dCLk1ypu+UzGfpTxcv IcLZdarOGAt4RPnvn2MmN7tt8JJQVgXpHg1EYx+pxsTw98vVBFNKfIHxpdQ7QI4TxPkU VkCMFa2TYKAsMsLTN5U2iiS3IeusZZlBCmx1cgTnpadGQPv9Om4gPsSxR0cBHYJQZz9g n+5TgYPXY8FZ4dEcbKa4a5n83YnAGtLPyuPOOqB4qpYMQJs9KHbwUh693sP0U7k/Nup/ DmkQ==
- In-reply-to: <20130307102251.4ff2e611@pwslap01u.europe.root.pri>
- List-help: <mailto:zsh-users-help@zsh.org>
- List-id: Zsh Users List <zsh-users.zsh.org>
- List-post: <mailto:zsh-users@zsh.org>
- Mailing-list: contact zsh-users-help@xxxxxxx; run by ezmlm
- References: <kh8d4u$mbp$1@ger.gmane.org> <20130307102251.4ff2e611@pwslap01u.europe.root.pri>
On 07/03/2013, Peter Stephenson <p.stephenson@xxxxxxxxxxx> wrote:
> On Wed, 06 Mar 2013 22:40:41 +0100
> Thorsten Kampe <thorsten@xxxxxxxxxxxxxxxx> wrote:
>
>> Zsh completion has always been kind of slow for me (in comparison to
>> bash) but I always contributed this to the superior functionality (my
>> .zshrc is two and a half times as long as my .bashrc).
>>
>> Today I decided that it had become unbearable and started investigating.
>>
>> I tested a simple completion like
>>
>> /us<TAB>r/bi<TAB>n/cada<TAB>ver.exe
>>
>> The directory completion (usr and bin) was already slow but the
>> executable (cadaver.exe) took ages.
>>
>> 1. Testing revealed that "setopt path_dirs" was responsible for the slow
>> directory completion.
>>
>> The zshoptions manual page says that path_dirs should not apply in the
>> above case[1] but a Process Monitor log showed that Zsh was actually
>> searching through the whole executable path.
>
> It's doing completion equivalent to:
>
> /usr*/bin*/cada*
>
> when you hit TAB in the last case. This is a feature, but definitely
> annoying in the case where path completion is slow. You can turn it off
> for the case where the directories exist by setting the style
> accept-exact-dirs to true: I've been doing this under Cygwin. In other
> words, this should complete /usr/bin/cadaver.exe faster the way you're
> doing it, since it's one component at a time, but still allows you to
> complete /u/b/c in one go.
>
> I don't think we have an option to turn completion of all path segments
> off altogether at the moment.
Isn't that what this does?
accept-exact-dirs
...
If you wish to inhibit this behaviour entirely, set the
path-comple‐
tion style (see below) to false.
path-completion
Explicitly setting this style to false inhibits this behaviour for
path components up to the / before the cursor; this
overrides the set‐
ting of accept-exact-dirs.
--
Mikael Magnusson
Messages sorted by:
Reverse Date,
Date,
Thread,
Author