Introducing His Grepship, by His Nerdship Pty Ltd  

His Grepship is a Windows-based visual tool that searches text files on your PC and network for search expressions (i.e. words or phrases). It can descend through sub-directories to extend the search. It runs on all 32-bit Windows systems.  His Grepship is loosely based on the UNIX grep utility. However, it goes much further than the original. Features include:

Enough talk. Let's move on the the first item, the main window:

As can be seen in the above example, His Grepship has sought all occurrences of the text TPositionForm in all files ending with .cpp, and .h in the directories D:\CPP work\Grepship and D:\CPP work\lib\include.  The found expression is highlighted in red.

Double-clicking any of these lines causes His Grepship to open the relevant file in the selected editor, and take you to the line and expression you clicked.

Neighbouring lines

Extra context information is displayed when you check the Neigbouring lines option.  His Grepship will then display the lines above and below the search expression.  In the following example, the user has requested 2 lines above the matching line, and 3 lines below.

 

Associated text editors

One feature of His Grepship that makes it very useful to software developers is its ability to activate either its own built-in editor, or optionally certain popular 3rd party editors. You can select an editor from the Choose a default text editor window.

When His Grepship performs a search and sends its output to the output list, you can double-click on an output line and the selected editor will be activated on the relevant file. The cursor will be placed on the correct line, and in most editors, on the search expression itself, ready for editing.

The built-in editor is pretty basic, based on the standard Rich Edit control. It has about the same capabilities as the standard Windows text editor Notepad.exe (i.e not very much!).  If you have one of the associated editors, you can download the relevant DLL and associate it with His Grepship.  Currently these editors are Vim, Lemmy, WinEdit and TextPad.  More can be added later if you can persuade me!

This is a shot of the built-in editor, after the user has double-clicked a line containing kIgnoreCase.

And a similar shot when Vim is the default editor:

Find and replace

You can also make global text replacements with His Grepship.  You can optionally confirm or reject each replacement, and as an extra safety measure you can abort all changes after you have made them.  Here the user wishes to convert selected instances of int to short.  As replacements are made, the original and modified lines are displayed in the main window.

 

 
 
 
Zenerx