45 ms·
As a quick and dirty test I tried running both Command-T and Ctrl-P against a directory tree containing some 26,000 XML files. Command-T takes roughly 10-15 sec
by michael_michael 14y ago
As a quick and dirty test I tried running both Command-T and Ctrl-P against a directory tree containing some 26,000 XML files. Command-T takes roughly 10-15 seconds to become responsive. Ctrl-P chokes and requires a Vim restart after invoking it against this directory.
- moe 14y agoThat should be a fairly trivial fix in both of them. Simply abort the scanning after a configurable threshold (either seconds or files). Needless to say that, yes, this must be implemented. I've choked my vim more than once by accidentally running Command-T or FuzzyFinder in the "wrong" directory. That should not happen.
- notJim 14y agoCommand-T definitely has the feature you're talking about (CommandTMaxFiles I think.) I'm not sure about CtrlP.
- amadeus 14y agoIf you are on Unix, add this to your vimrc and the directory indexing speed should go through the roof: https://gist.github.com/ee14d6ecb9196a07da56 https://gist.github.com/ee14d6ecb9196a07da56
- jamesgeck0 14y agoIs that offloading the task of scanning file names to the find command?
- shurane 14y agoIs there a reason that Ctrl-P, FuzzyFinder, and Command-T choke on large directories? On windows, I've used this piece of software called Everything Search that seems to index the entire filesystem (say around 30,000 files) in under 5 seconds. That's really impressive and I love using it for that. But it makes me sad to use these vim extensions choking on directories of similar size. Maybe NTFS vs ext4 has something to do with it?