Search in files
-
Is this is a bug?
Precondition: I have a file open in notepad++ and the file content is currently out of sync.
Problem: When I search via find-in-files and the opened file is in the same folder, then only the out of sync content for this file is searched. I would expect that it is searched the complete content of the folder, independent what is open. -
it is expected, open buffer beats saved file.
-
I suppose if you really want to search the saved-file and not the open-buffer, and you have no other good way of searching available to you (an independent utility of some sort, say), you could start another instance of N++ and use that to search it.
For myself I rarely make a lot of changes to a file that I don’t intend to keep. Thus I’m on the “save” key often. Thus for me “saved-file” and “open-buffer” are the same thing, so I don’t run into the situation.
-
I am reading log files which are being constantly written.
-
@Ekopalypse aha ok. But this is not intuitive. For the open buffer exists the option “find in open files”
-
Hello, @stefan-vienna, @ekopalypse, @alan-kilborn and All,
-
Open a
CMD
prompt window -
Type in the command
notepad++ -multiInst -nosession
and valid
=> A new N++ instance should open with, only, the
new 1
tab-
Open the
Find in Files
dialog of that new instance -
Perform your searches
This time, it will search ONLY inside true saved files, even if some of these are presently modified by an other N++ instance ;-))
Best Regards,
guy038
-
-
@stefan-vienna said in Search in files:
But this is not intuitive
Oddly, to me, it would be less intuitive for a text editor’s “search” function to search the disk contents instead of what was actively in the editor (and in some cases – like a new file – be completely meaningless).
-
Searching the disk content of an open file is problematic…because, well, how does N++ do this type of searching?
It opens the file into a tab that isn’t shown to the user, for each file searched. Since it can’t easily open two tabs for the same file (hmmm, cloned view does it, though…?), this type of thing isn’t allowed.