4

I'm using Projectile to index a Rails 4 project. When I use M-x projectile-find-file to locate files using their file name, some files simply don't appear.

For example, I have a file located in app/controllers/api/v1/test_controller.rb, but typing M-x projectile-find-file entertest_controllerenter returns no results.

Is there a way to re-index the project, or figure out what's filtering out certain files?

5

The quick answer is to invalidate the projectile cache. When using projectile-find-file if you use C-u to send the universal argument before running the function, it will invalidate the cache before searching it. To match your example;

C-u M-x projectile-find-file

There are a number of other functions in projectile that use the prefix argument, check for any that call projectile-maybe-invalidate-cache if the universal argument is present.

More generally though, projectile provides projectile-invalidate-cache which is by default bound to C-c p i.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.