-
Notifications
You must be signed in to change notification settings - Fork 0
Home
jonas054 edited this page Jun 3, 2011
·
5 revisions
The reason I wrote a find+grep style search tool is that I wanted something very similar to the find+grep combination with a bit of tailoring added for searching in source code. The functionality I wanted really needed an implementation made from scratch and couldn't be achieved just configuring and adding to find+grep.
These are some of mlgrep's features, roughly in order of importance.
- Searches for matches across line breaks in texts. Since line breaks and other forms of white space are insignificant in many programming languages, this is necessary.
- Can find files recursively through directory trees, and recognizes a few file types and associates them with the correct languge. Differentiating between languages is necessary for skipping (see further down). Some languages such as C, C++ and Java are built-in. Others can be configured in ~/.mlgreprc.
- Adds some shorthand to the normal regex syntax. A single space means any combination of whitespace, and \u means "until".
- Can skip comments and strings when searching for matches.