Closed dcDeba closed 1 year ago
Do you have 'autochdir'
set, by any chance? (See :h 'autochdir'
). That setting causes Vim to change directory every time you open a file, which causes Command-T to have to re-scan from the new "root" directory.
See also :h g:CommandTMaxCachedDirectories
, which lets you choose how many directories get cached.
I checked if autochdir is set or not using the below command: command--> :verbose set autochdir? Output--> noautochdir
I have set g:CommandTMaxCachedDirectories to the following in .vimrc
let g:CommandTMaxCachedDirectories=0
Must be something else going on then. This is with the standard :CommandT
finder, right?
Can you confirm that :pwd
is stable and not changing?
There might be something unknown to me in your local environment that is causing Command-T to drop its cache; there isn't anything internal to the plug-in itself that would do that, other than the things I just said.
Yes, with standard :CommandT finder.
I have opened the same file twice and checked the output of :pwd and its same.
Is there any way to specify the cache path?
Also, what is the name of the cache file and in which directory is it created.
It's not a file; it's an in-memory cache — as in, if you quit Vim, the cache is gone.
Okay! Is there any way I can debug the issue?
You could try disabling all other plugins and starting with an empty .vimrc
; like I said above, there's nothing internal to Command-T that would cause it to rescan a cached directory.
Given the big rewrite for v6.0.x, I'm closing all older issues as there is unlikely to be anything significant happening on the 5-x-devel
branch from here on[^patches]. Feedback issue for 6.0.x is here:
[^patches]: Patches and PRs would be welcome, but my personal efforts are going to be directed towards main
.
Every time I try to open command-t on a file, it starts searching for all the files making the vim unusable. How to cache the result and use the same cache in multiple files.?