'How do I exclude a list of folders in Search in Notepad++
I have searched online and have not yet found a direct stack where someone is saying this is an example of all common folders of 2020 to ignore, that unofficial list would also be a nice edition to this post. I will add some:
bin node_modules dist
Please add the remaining and what to enter as a string here with correct syntax, example correct the below string question:

Solution 1:[1]
From what I can tell, exclusion of directories (in the Filters field, at least) isn't supported in Notepad++ (as of early 2021).
There's a silly hack where you add the HIDDEN attribute to a directory using File Explorer, then ensure the In hidden folders checkbox in the Find in Files dialog is unchecked.
The directories I usually want to exclude contain binaries that sometimes cause Notepad++ to crash during a Find in Files.... Best I've been able to do is to include a long list of exclusions, e.g.:
*.* !*.a !*.bak !*.bin !*.bmp !*.cache !*.cur !*.db !*.db-shm !*.db-wal !*.dll !*.dmp !*.DS_Store !*.exe !*.exp !*.icns !*.ico !*.ide !*.ide-wal !*.idx !*.iobj !*.ipch !*.ipdb !*.jar !*.lib !*.lock !*.log !*.mdb !*.mp4 !*.msi !*.nib !*.nupkg !*.o !*.obj !*.opendb !*.out !*.p7s !*.pack !*.pch !*.pchast !*.pcm !*.pdb !*.png !*.res !*.ser !*.so !*.sqlite !*.suo !*.sym !*.tif !*.tiff !*.tlog !*.user !*.winmd !*.xcuserstate !*.xls !*.xpm
Your list will likely be different, of course. Note that the inclusion(s) go first, followed by the exclusions.
I saw a post that claimed that the contents of the Filters field was limited to 255 characters. I haven't checked to verify whether that's (still) true, but it's something to watch out for.
Solution 2:[2]
This is a feature added to v8.2: "Add exclude folder(s) ability in Find in Files". In the application, hover your cursor over the "Filters" label in the "Find in Files" dialog to see usage examples, including these relevant ones:
Find in all files but exclude folders test, bin & bin64:
*.* !\tests !\bin*Find in all files but exclude all folders log or logs recursively:
*.* !+\log*
To accomplish what you're describing, you could try:
*.* !\node_modules !\bin !\dist
Or, to exclude those folders recursively:
*.* !+\node_modules !+\bin !+\dist
I find this to be useful:
*.* !+\node_modules !+\bin !+\obj !+\lib !+\packages
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Scott Smith |
| Solution 2 | JustinStolle |
