1

I followed the docs here and added lines to .projectile like

-/build
-/Docs/doxy

I did that because I want typical projectile commands to ignore those sub-directories in my project directory.

My "project" is pretty typical. It is a hierarchy of directories with source code files, CMakeLists.txt, and other things. I put this .projectile file in the root folder to mark it as a project for projectile. That part seems to work, because the various projectile commands seem to be using that folder as a project root now.

However, when I run projectile-find-file, and then type part of a filename in the minibuffer, it doesn't just match against source code, it matches object files in the build directory, and .html files generated by doxygen in the Docs/doxy directory. I usually don't want to open these things in emacs, and I'd like it to ignore these files.

Shouldn't it be ignoring them, because I added those lines in the .projectile file?

Maybe I should also mention I enabled IDO with (ido-mode t) so when I'm typing in the minibuffer to find the file it's matching any file in the tree, going into subdirectories. Eg, I type "View.cc", and the displayed list of potential matches looks like:

MyApp/BrowserView.cc     (good)
MyApp/PracticeView.cc
MyLib/UILib/View.cc
build/CMakeFiles/.../BrowserView.cc.o    (bad)
... many more ...
5
  • Please summarize what actions you took - a recipe, instead of just providing a link.
    – Drew
    Commented Sep 24, 2022 at 21:53
  • I've updated the question to try to explain a bit more.
    – Rob N
    Commented Sep 25, 2022 at 13:44
  • Thx............
    – Drew
    Commented Sep 25, 2022 at 16:13
  • Just a wild guess, it may or may not work ... Projectile has a cache. May be it hasn't refreshed the cache after you have update `.projectile. Try creating the project refresh, or re-create the project cache using one of the projectile's cache commands.
    – user31220
    Commented Sep 26, 2022 at 8:11
  • I tried projectile-invalidate-cache, and restarting emacs. No luck.
    – Rob N
    Commented Sep 28, 2022 at 20:40

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.