ctrlp.vim icon indicating copy to clipboard operation
ctrlp.vim copied to clipboard

many files not findable

Open dyfrgi opened this issue 12 years ago • 7 comments

$ cd ~/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/test-unit-2.5.2 $ ls lib test test-unit.rb vim . ^p test-unit.rb == NO ENTRIES ==

I'm not sure why, but for some reason nothing in subdirectories of gems under ~/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems gets found. This is rather annoying if I'm exploring the code of a gem in there.

If I copy the directory into my homedir, it does then work, though it's rather slow since the root it finds is in fact ~.

I think this is an actual issue, though I'm open to the idea that PEBKAC.

dyfrgi avatar Dec 06 '12 14:12 dyfrgi

Further investigation shows this is due to max_files. There are, uh, a lot of gems in there, and the root it's finding is probably ~/.rbenv, as that's a git repository. Going to have to think about reasonable roots to make this work. It also might work to have CtrlP load nearby files first, before loading ones which are further away. Or maybe say something when the max files is hit, instead of just silently ignoring a bunch of files that it seems like should be found?

dyfrgi avatar Dec 06 '12 15:12 dyfrgi

Duplicate of #313. But good idea about adding an indicator for hitting max_files. I'll see what I can do.

kien avatar Dec 06 '12 23:12 kien

One possible solution is to verify if the .git directory exists under the current gem directory..

rainerborene avatar Feb 18 '13 01:02 rainerborene

A message when max files is hit would be awesome, I was unaware of this because of ignores I had already reached the default 10k limit but CtrlP only showed itself as indexing 5813 so I thought it was some other issue.

DeMarko avatar Feb 28 '13 18:02 DeMarko

I just noticed that because the match window is not scrollable it was always missing files that I was looking for.

timc3 avatar May 29 '13 08:05 timc3

Added that to .vimrc fixed for me: " Unset cap of 10,000 files so we find everything let g:ctrlp_max_files = 0

marr avatar Apr 16 '14 03:04 marr

This issue caught me by surprise when I switched from Command-T to CTRLP. My current workaround is to use the VCS ctrlp_user_command as per the docs:

  let g:ctrlp_user_command = {                               
    \ 'types': {
      \ 1: ['.git', 'cd %s && git ls-files'],                
      \ 2: ['.hg', 'hg --cwd %s locate -I .'],               
      \ },                                                   
    \ 'fallback': 'find %s -type f'                          
    \ }

ncjones avatar Dec 08 '14 09:12 ncjones