Easy Console Grepper is a Grep Console Plugin for the Eclipse IDE. It integrates itself in the Eclipse IDE Console View.
The recommend way to install, visit the
Eclipse Marketplace or drag this icon into your Eclipse IDE.
You can also visit the SourceForge Project Page and download the PlugIn as ZIP-Archive.
To see the latest release changes, see
changelog.txt.
There are some other Grep Console Plugins, but none of them can offer the features what I needed. So I decided to write my own "Grepper".
Easy Console Grepper can observe any "Source Consoles"
(at least Text Consoles like a Java Launch Console or OSGi Console) and filters ("grep") each line of it where occurrences of the given
Search String or Regular Expression are found.
Before open a new "Grep Console", be aware you have already open a Text Console.
Open a new Grep Console like this:
In the upcoming dialog, choose your Source Console to observe, edit your Search String
and set other search options like Case Sensitive.
You can always open this Settings-Dialog by clicking the icon .
Here you see a Grep Console at work grepping the string "de.jepfa":
You can open more than one Grep Console and watch for different
occurrences. Here you see two Grep Consoles (#1 and #2) grepping different characters at the same
Source Console. Tip: Pin your Grep Consoles to attach.
Use New Console View to open more Console Views and switch to your desired Grep Consoles.
Easy Console Grepper provides a customizable match-highlighting and a Source Console related line numeration.
But the clou is the opportunity to restart automatically watching ("grepping") a
temporary disposed Source Console.
This is useful when you run for example a Java-Application many times. You don't need to "reconnect" manually to the
Java Launch Console, Easy Console Grepper does this automatically for you! A hint "resume console grepping..." is printed to the Grep Console in this case.
An other core feature is the possibility to filter Ranges of lines. That means
you define a Start Expression and an End Expression in the Settings-Dialog.
Therefor you have to enable the "Range Matching" check box.
All lines between the Start- and the End Expression matches will be additionally shown as "Match Ranges".
Here you can see a range match from "^620" to "^625" (both as Regular Expressions).
Furthermore you are able to store any Grepper-Settings from the Settings-Dialog as Preset for future uses.
Store your Grep-Settings as Presets.
There are some Default Presets. The preset for Java Exceptions is very special, I hope it works for you.
(If you have a better RegExp, please tell me :-) )
"Regrep" the complete Source Console on demand by clicking this icon . The whole content of the Source Console will be passed again to the Grep Console. This is useful when you have created the Grep Console after the Source Console has yet printed something out.
Enable/disable filter with this toggle icon . When not toggled, it let pass not matching lines of the Source Console. Here you can see a disabled filter passed the complete output of the Source Console and the match line that matches the character "2":
Show statistic data for the current Grep Console. This icon will bring up a dialog with the current match count, Match Range count etc. The data are updated permanently, but you can stop/start this. Also you can reset the statistic data (only) for the Grep Console.
Hyperlink-Support for Java Exception Stacktraces. You can click to an Stacktrace Element (unfortunately I was not able to underline the link :-( ) and the corresponding file will be opened and the line will be selected.
To join the Easy Console Grepper Preferences click on this icon or open the Preferences of the Eclipse Windows menu.
The general Preferences will be shown.
Here is a description for each option:
Grep Console buffer size | The maximum of characters shown in the Grep Console. Valid values are from 1.000 to 5.000.000 characters. When the total amount of characters exceeds this value, at least 10% of the top of characters are deleted - always full lines are deleted. |
Show line numbers of Source Console | Enable this option when you want to see on Grep Console the Source Consoles origin line number. The line number is colored to be different to the Source Console text. To change those colors, see Customize Colors. |
Show timestamps | Enable this option when you want to see on Grep Console the current timestamp (hh24:mi:ss.sss) the line is grepped. It is colored to be different to the Source Console text. To change those colors, see Customize Colors. |
Highlight matches | This option shows all matches (block matches too) with a different color. The matching characters depends on your Search String / Regular Expression. To change those colors, see Customize Colors. |
Resume terminated / disposed Consoles (beta) | This is the key option of that all! If enabled and a Source Console is disposed and recreated again, the Grep Console will be automatically reconnect to the recreated Source Console. This is done by the name of the disposed and recreated Source Console. Both must match (digits are removed from this check)! |
Activate Grep Console at resuming | When Resume terminated / disposed Consoles (beta) takes in effect, this option will bring up those Grep Console to the top of your Console View view stack. |
Clear Grep Console at resuming | When Resume terminated / disposed Consoles (beta) takes in effect, this option will clear current Grep Console content. |
Don't ask before change / regrep a disposed Source Console | That means, if you "regrep" or open the Grep Console Settings connected to a disposed Source Console, the Question Dialog to close the Grep Console will be not shown. |
Show End Expression matches outside from ranges (Range Matching only) | Enable this option, when you want to grep also End Expression matches outside from Match Ranges. That means, an End Expression match is shown after an other End Expression match and before a Start Expression match. It only works for Range Matching mode. |
Show Grep Console hints | Disable this option when you don't want to see any generated hints on the Grep Console, e.g. "resume console grepping...". |
Time in seconds to print marker string after Source Console was silent | This is a generated hint like descriped at Show Grep Console hints. The hint is coming when Grep Console was idle for at least x seconds before new matching lines coming in. |
Number of subsequent lines after matches | When a line match occures, x additional (not matching) lines will be printed on Grep Console. Good option to see "behind" a match ("before" is not possible). |
Here you can customize the Grep Console colors for matches (range matches as well) and line numbers:
At this Preference Page you can change the Grep Update Strategy. That means, when the Grep Console prints incoming characters from the Source Console.
Update at every change event | Updates immediatelly, also STDIN characters. Extreme long lines will be wrapped. STDIN characters are printed one by one at a new line. |
Update at new-line characters | Updates not immediatelly, not before a new-line character occurs. So you will see STDIN characters from Source Console not before you hit ENTER. |