Sublime Forum

Search doesn't work

#1

I noticed that sometimes search does not find things. For example I was searching for a specific symbol in a whole C project and sublime text 3 is able to find some of its occurrences but not all! The search is a simple search, no match case no whole word, just a search for a symbol in whole project. For a moment I thought the symbol is not defined but then in the command line I did “grep -ir MY_SYMBOL .” and of course it is. Just sublime can not find it.

PS: I think it may has to do with the fact that it is defined in a recently added fine - maybe sublime doesn’t update its index? Also, I do a lot of git checkouts to a branch that does not have it. Maybe that is also confusing ST?

Thank you.

0 Likes

#2

Do you have the “Use gitignore” option in the find in files panel enabled? Perhaps that’s not something you want.

0 Likes

#3

I had this feature enabled but after I turned it off the search results are exactly the same. Also, this SYMBOL is defined in a legit project file so it is not subject of gitignore anyway.

0 Likes

#4

Not sure what you mean by “legit” project file, but generally the only influence sublime projects have on find-in-files is which folders should be searched in by default. Are you sure the files you’re expecting to show up in the search results are visible in the side-bar? If they are perhaps they’ve been excluded by the "binary_file_patterns" setting.

0 Likes