From: Mikael Magnusson <mikachu@gmail.com>
To: Peter Stephenson <p.stephenson@samsung.com>
Cc: zsh-users@zsh.org
Subject: Re: Slow completion
Date: Thu, 7 Mar 2013 12:44:55 +0100 [thread overview]
Message-ID: <CAHYJk3Tq1W2f_mRYFyV1ZrNQUgyK9u_GAoD6cAZc9ofx6r7bCA@mail.gmail.com> (raw)
In-Reply-To: <20130307102251.4ff2e611@pwslap01u.europe.root.pri>
On 07/03/2013, Peter Stephenson <p.stephenson@samsung.com> wrote:
> On Wed, 06 Mar 2013 22:40:41 +0100
> Thorsten Kampe <thorsten@thorstenkampe.de> 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
next prev parent reply other threads:[~2013-03-07 11:45 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-03-06 21:40 Thorsten Kampe
2013-03-07 10:22 ` Peter Stephenson
2013-03-07 11:44 ` Mikael Magnusson [this message]
2013-03-07 12:08 ` Peter Stephenson
2013-03-07 16:04 ` Bart Schaefer
2013-03-07 20:33 ` Thorsten Kampe
2013-03-07 23:38 ` Oliver Kiddle
2013-03-08 15:45 ` joe M
2013-03-11 16:21 ` Bart Schaefer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAHYJk3Tq1W2f_mRYFyV1ZrNQUgyK9u_GAoD6cAZc9ofx6r7bCA@mail.gmail.com \
--to=mikachu@gmail.com \
--cc=p.stephenson@samsung.com \
--cc=zsh-users@zsh.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).