Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

PhpStorm global search not working

Tags:

phpstorm

In the last two weeks, and for reasons unknown to me, PhpStorm has stopped finding strings in project searches (although I know they are there). I have the latest version of PhpStorm installed.

Ctrl + Shift + F goes through the motions but returns nothing.

Does anybody else have this problem and a solution?

like image 962
TheRealPapa Avatar asked Nov 17 '16 22:11

TheRealPapa


People also ask

How do I search globally in PhpStorm?

From the main menu, select Navigate | Search Everywhere or press Shift twice to open the search window. By default, PhpStorm displays the list of recent files.

How do I search for a directory in PhpStorm?

From the main menu, select Edit | Find | Find in Files Ctrl+Shift+F . In the search field, type your search string. Alternatively, in the editor, highlight the string you want to find and press Ctrl+Shift+F . PhpStorm places the highlighted string into the search field.

How do I search an entire project in WebStorm?

Press Ctrl+Shift+N and start typing your query, CamelCase and snake_case are supported. The list shrinks as you type. Select the file or folder you need and press Enter . If you selected a file, WebStorm opens it in a new editor tab.

How do I search for a file in a project?

Find the search string in a projectPress Ctrl+Shift+F or select Edit | Find | Find in Files from the main menu. In the search field, type your search string.


1 Answers

Please use File | Invalidate Caches... and restart IDE -- it usually helps in such "suddenly stopped working" situations (similar to "reboot your PC" solution).

The reason is that some indexes got broken or out of sync for some reason .. and this action just marks all caches and indexes as "invalid/damaged" so IDE will discard them on next launch (you can check idea.log for exact wording).

Please note that this will also discard your Local History in case you are using it.

like image 175
LazyOne Avatar answered Nov 05 '22 17:11

LazyOne