From: Stefano Crocco Date: 2011-11-02T16:11:18+09:00 Subject: Re: A ruby version of grep? On Wednesday 02 November 2011 06:19:20 Marc Heiler wrote: > I need a grep variant in pure ruby. > > Like the unix grep. > > It does not have to support many fancy things... > > Colours (so the result can be colourized) and recursive searching of > files. > > The rest does not matter. > > Has anyone written such a class? I am asking before I write my own > version of grep. There's rak [1], although I don't know exactly what kind of colour support you need. If you use ruby 1.9, you may want to apply the patch described in the pull request in rak's github page. Without it, it'll stop at the first non- ASCII character it finds. Stefano [1] https://github.com/danlucraft/rak