Programster's Blog

Tutorials focusing on Linux, programming, and open-source

Netbeans - Speed Up Search By Ignoring Certain Folders

I was working on a project recently which had over 1000 NPM packages installed. This meant whenever I ran a search, it always got delayed as it went through the node_modules folder. This is code I don't really care about because it's packaged code that I can assume to be working and I don't need to look at. Wouldn't it be great to just automatically skip this folder when running a search? Here's how.

Steps

Go to tools -> options

Then select Miscellaneous -> Files and update the Ignored Files Pattern field to include the names of the folders you wish to ignore.

For example, I wanted to ignore all the files within the NPM packages that were installed, so I included node_modules. This dramatically sped up my search.

My pattern is now

^(CVS|SCCS|node_modules|vssver.?\.scc|#.*#|%.*%|_svn)$|~$|^\.(git|hg|svn|cache|DS_Store)$|^Thumbs.db$

References

Last updated: 30th June 2021
First published: 10th June 2019

This blog is created by Stuart Page

I'm a freelance web developer and technology consultant based in Surrey, UK, with over 10 years experience in web development, DevOps, Linux Administration, and IT solutions.

Need support with your infrastructure or web services?

Get in touch