Exclude folders from Eclipse search

前端 未结 6 968
逝去的感伤
逝去的感伤 2020-11-28 00:52

Is there a way to exclude certain folders (and all their subfolders) from searching within Eclipse?

6条回答
  •  抹茶落季
    2020-11-28 01:21

    The quick and dirty way:

    Right click on a folder, go to properties, and mark a folder as derived. Derived entities are excluded from searching by default. The problem with this approach is that Eclipse "forgets" that the folder is derived if you delete it (either from within Eclipse or externally, followed by refreshing the project tree). Like so often with Eclipse, this is a long-standing bug (10 years in this case) which still applies to the current version (4.6 Neon at the time of writing).

    The safe way:

    Create a working set including only those entities you want searched and search only within that working set. See Dave Ray's answer for details on this procedure.

提交回复
热议问题