Search for Folder Name Using Eclipse "Search in File" - eclipse

How can I use 'search in path' for Eclipse Mars 2.0 to find a string pattern in either the name of a file and also find a string pattern in the name of a folder?
I have a folder named 'Personal Finance' in a git repo that I primarily use Eclipse to work with. When I search in file for 'Finance' the only search results that show up are in files themselves. Is there a way in Eclipse to search file names and folder names simultaneously?

Do not use Search dialog(Ctrl+H) for this. It searches inside the file content.
Use open resource dialog(Ctrl+Shift+R).
In the input pattern text box enter
<Folder/File NamePatter>/
For example:
*handler/
This will list all files which has handler string in their names and present under the folders which has handler string in their names.
*handler/*nature
This will list all files which has nature string in their names and present under the folders which has handler string in their names.
See this post for more details When typing in Open Resource dialog, is there a way to find files by directory instead of just the file name? also look into this bug and read all comments.
This may not interest to you but have a look on it:
In this blog you can find the details of a plugin which filters resource in package explorer view by name patterns. But now its limited to filter only projects. Go through this bug and this bug

Related

In VS Code how to search in a project/directory through file content AND file names

I have a VS Code project where I want to search for a string, say "MyDataProvider".
This string appears in the content of some files (as part of URL strings) and in the name of another file (which is the data provider).
How can I search for both in VS Code? The Find in Files command searches only the content.

Visual Studio Code file filter behavior

I've opened a folder in vscode and have a fairly a large file structure to navigate. It would be very helpful if I were able to filter across those files in a way that showed only the file names that containe the filter string while still showing their location in the file hierarchy. I could have sworn that I've done that before but now have lost it.
We do have highlighting in the Explorer pane, by selecting the explorer pane and starting to type. The difficulties there are that it:
Highlights files but doesn't eliminate unmatched files
Doesn't expand folders that contain the matched files
Does a confounding search that is the equivalent of putting a wildcard between each character typed
Do extensions exist that do all of the following?
Filter the file names based on search string (i.e., hides the unmatched files)
Expand the folders that contain the matched file names
Allows for exact search (or regular expression)

Eclipse - Search for a word or Phrase inside the package

Is there a way I can "find a particular word or phrase" in a package/project(in all files in the package/project), without going to each and every class file and do the ctrl + F thing.
Let's say I have a template project for schools. I just need to change the school's name with the needed name. I know I can keep this as a constant and do, but I am just giving you a scenario.
My requirement is that I find all files where the particular pharse or word exists in the package and change it.
Search -> Search... or ctrl+H. There is File Search where you can search by text or regular expression and restrict search by scope and/or file name patterns. And there is Java Search which allows you to find declarations, references and occurrences of Java elements.

Eclipse find all in one file

In Eclipse (CDT), is there a way to find all occurrences of a string in a single file? I can search the entire workspace easily enough using Ctrl-H, and can do "find-next" using Ctrl-F, but I want to be able to see a list of all matches for just one file.
It would be possible to do by setting up a custom file filter for each file I want to search, but that's very clunky. Eclipse should be able to work out which file I have open and just search that file.
This seems like it should be easy, but I can't find an appropriate option...does it exist?
Use CTRL+H and switch to File Search as you already mentioned, but set Scope to Selected resources. Now you can either search the current file, or selected multiple files and search all of them

How to skip .svn-base files in file search of Eclipse?

Whenever i perform a file search in eclipse, it scans all files including .svn-base file.
Provided i am using * for file name patterns.
Is it possible to scan all files for searching but skipping the .svn-base file?
It is possible. But the search pattern is inclusive and not exclusive. You can click on Choose button and select the file types you wish to see in your search results.
You also have custom plugins for excluding .svn and .cvs directories during searches.
If you have Subclipse, the search filtering is included.
Note: since Eclipse Helios 3.6M3 (October 30, 2009), you can actually exclude resources from your project, making the search more precise as a result.
alt text http://download.eclipse.org/eclipse/downloads/drops/S-3.6M3-200910301201/images/resourceFilters.png