Find in Files

It is often the case when editing project files that you need to find information in other files. Typically this involves switching to the command line and performing cd and grep commands and then finding/opening those files back in an editor. Nothing like performing a bunch of extra steps to pull you out of the coding zone…

 

For these types of operations, TKE has your back with its "Find in Files" feature.  Just invoke it from the "Find / Find in Files" menu option and the following input panel is displayed.

The "Find" entry field allows you to specify a regular expression as a search pattern to find within a group of files/directories. So if we wanted to find all occurrences of the keyword "foobar" at the beginning of a line (with optional spaces between the beginning of the line and the keyword), we could enter the following:

After entering the TAB key, the input focus will rest on the case sensitivity switch.  By default, the value of this switch is to search in a case sensitive mode. Hitting the TAB key again will perform case sensitive matching. Hitting the SPACE bar followed by the TAB key will change to case insensitive matching.

The "In" input field allows the user to enter one or more directories, files or specialized group of files to perform the search. Entering a value followed by the ENTER key will tokenize the current value. You can select one or more tokens in the field and hit the BACKSPACE key to delete the tokens or double-click one to change its value.

Entering a value in this field will display a dropdown list of matching files/directories that are accessible within the sidebar. Select a value in the dropdown list by using the UP and DOWN keys and hitting the ENTER key to select a value.

Once the desired directories/files have been entered, hitting the ENTER key one more time in this field will perform the file search. In a few moments, TKE will display a "Results" buffer which will display the list of matches along with some contextual information. All matches will be highlighted within the editor and left-clicking on any match will automatically open the associated file within the editor and jump to the matching line, placing the insertion cursor at the matching value.

To see more information about the TKE code editor, visit http://tke.sourceforge.net

Advertisements
Find in Files