Search code examples
eclipseeclipse-cdt

Eclipse: how to hide custom files in Project Explorer


I have a custom builder in CDT, which adds alot of files into project directory. I want those files to be filtered out from Project Explorer, but cannot figure out how (the file mask is *.ooj).

Is it possible to add a custom filter by file mask into Customize View? Or maybe there is anther way to hide files in Project Explorer?


Solution

  • Here's how to do it on Eclipse Indigo/Luna/Neon (as of 2018-05-22):

    • Open the "project properties"
      • pull down menu --> Project --> Properties
      • A new dialog window named "Properties" will appear
    • Create a "Resource Filter"
      • Select Resource --> Resource Filters -> Add Filter...
      • A new dialog window named "Add Resource Filter for project" will appear
      • In the new dialog select the following
        • Filter Type: Exclude All
        • Applies to: Files
        • Make sure to click the checkbox for "All children (recusive)"
        • File and Folder Attributes
          • select: Name
          • select: Matches
          • fill in: *.ooj
        • Click OK
        • Dialog closes
    • Apply the new filter
      • Click Apply
      • You should see a change in your "Navigator" View
    • Close the "Project Properties"
      • Click OK
    • Done