you can just define a key binding that opens the file search:
- go to preferences > general > keys
- type "file search" in the search box. (if there are no results, and you have a really old eclipse version, select the include unbound commands check box.)
- put the caret into the binding text box and press the key combination you want to use:
you can either re-use the ctrl+h binding (delete the other binding in that case) or define another one (e.g. ctrl+shift+h). to delete the other binding search for "open search dialog" and click on unbind command.
other solution: you could press ctrl+3 in your editor, type in "file s", press enter. the next time you press ctrl+3 "file search" is at the top.
update: user @muescha, in the comments underneath the question, just pointed out to me that i accidentally answered the wrong question! nevertheless, it is still a valuable answer (just not to this question), so i'm leaving it.
my answer answers the question: how do i use a hotkey directly to search for a file in eclipse?
ctrl + shift + r works fantastically! use asterisks (*) for wildcards. it is very similar to the ctrl + p fuzzy search in sublime text 3.
sample searches using the ctrl + shift + r "open resource" search in eclipse:
notice if you just put an asterisk
* between every character in the search string it works just like sublime text 3's ctrl + p "fuzzy search"! beautiful!
side note: you can also use the search --> file menu dialog to search for files.
as far as i know, the search window tab depend of the open file you're on when calling the search function. so, for example if your on a web.xml file, it will open the "plug-in search" instead of the "java-search".
edit: there is a way to force the default open tab, by assigning a shortcut to the "file search" action in the "keys" preference panel.
probably this feature came recently [confirmed its there in since juno] and looks intelligent. press ctrl+h --> customize --> [checkbox] remember last used page. this way you are not far from other options if required anytime. so if you use file search often then you will not get annoyed getting what you last chose.
i've run into this problem before, too.
i tried following the advice in the question response given by @martin to rebind ctrl+h to "file search" in window | preferences | general | keys, but for some reason, i don't have a "file search" entry in the command column. (i'm running eclipse 3.3 currently; maybe the "file search" entry was added in a subsequent release?)
update: as martin pointed out in a comment on this answer, i didn't have the "include unbound commands" checkbox checked in the preferences | keys dialog, which is why "file search" wasn't showing up for me. i now have ctrl+h bound to "file search", as martin suggested in his answer on this page, and it works great. thanks martin!
i ended up working around the original problem by bringing up the search dialog with ctrl+h, then clicking the customize button on the dialog, which brings up a "search page selection" dialog which allows you to hide or show tabs on the search dialog. i hid the tabs other than "file search," which causes "file search" to be activated by default on future uses of ctrl+h.
i learnt to use a "pseudo-hotkey" alt+a f (works also as alt+a alt+f), which resolves to: "menu se[a]rch → [f]ile..." and has the advantage of being always present, without need for reconfiguration.
i actually think the best (and easiest way) is to simply open the search dialog (ctrl + h), hit customize, and then select the checkbox for "remember last page used." then tab over to the file search once. so long as that is the last search tab you used, it will always open there. the advantage to this is that you don't lose easy access to the other tabs, should you actually need them! (working in eclipse kepler).
another option is to open the search dialog (ctrl+h) then click customize and hide java and task search tabs, next time you do ctrl+h, file search will be the only one showing, thus it will be selected by default
- How do I hotkey directly to File Search tab in Eclipse
- How can I make Eclipse file search not include svn directories?
- How to ignore tab spaces in eclipse cvs file compare?
- How can I get Eclipse File Search to skip certain files?
- How to search for a file inside Eclipse CVS Repository without doing check out
- how can I instruct Eclipse to search for my AndroidManifest.xml file in another folder?
- How to search for a file from Eclipse Plugin?
- Eclipse file search - How do I search for a particular string
- How to prevent Eclipse use existing file tab when opening a new file
- eclipse "find all references" - how do i limit file types for this search
- How to remove files from Eclipse IDE File Search
- How to search inside current xml file in eclipse
- How do I show an open file in eclipse Package Explorer?
- How to attach source or JavaDoc in eclipse for any jar file e.g. JavaFX?
- How to solve "Unresolved inclusion: <iostream>" in a C++ file in Eclipse CDT?
- Eclipse Editor: How to change file format from Dos to Unix
- How to make eclipse "File Search" to also search inside source jars containing some text?
- How to cancel search highlight in Eclipse
- Excluding file types in Eclipse / Aptana find in files search
- How to enable the bar showing file location in Eclipse
- How to make war file in Eclipse
- How Do I Automatically Generate A .jar File In An Eclipse Java Project
- Eclipse Short Cut: File Search
- How to search for carriage return in eclipse
- How to change search background color in eclipse
- How to navigate to the last cursor position in Eclipse if it is in the same file and was not edited?
- Eclipse file search finds the same file multiple times
- How can I disable compiler warnings in Eclipse on a file specific basis?
- How to tell eclipse to ignore: "No persistence.xml file found in project"
More Query from same tag
- Getting "Module javafx.controls not found" error Java Eclipse IDE
- Importing android-crop library in my project
- How do I let eclipse report unreported exception in completable futures?
- How to insert a log in LogCat that when I click on it jumps to its line in code?
- Problem with running a program on Pydev in Eclipse
- What is the performance hit from using SWT_AWT Bridge in Eclipse RCP
- protected variable from super class not visible from subclass in different package
- Eclipse CDT variable colors in editor
- Error starting jboss server
- class not found exception after replacing library in eclipse
- How to use if(DEBUG) in java in eclipse?
- How to programatically clear application cache in Android 4.2.2 and above
- how to import jms
- How to get the inline command launch by eclipse
- Importing an existing project to eclipse is giving me a lot of errors
- Select sun Java version 7 via command line in linux
- Error in eclipse, when import coverage?
- how to save menuitem visibility state through sharedpreferences?
- Any way to generate ant build.xml file automatically from Eclipse?
- What are the good "rich" IDEs for Lisp?
- Show coloured log4j output in Eclipse console
- Running Android App From Emulator
- How to find where a method is used in Java project
- External jar Files in Java
- M2E: Version is duplicate of parent version - Why is this a warning?
- CoreException: Could not get the value for parameter compilerId for plugin execution default-compile: PluginResolutionException
- Weird ActivityNotFoundException for class in a library project
- org.eclipse.swt.SWTException: Invalid thread access from HandledContributionItem
- How to update layout after onConfigurationChange?
- How can I ignore build directory in Subclipse?