bug-grep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Patch for transparent decompression


From: Reuben Thomas
Subject: Re: Patch for transparent decompression
Date: Sun, 27 Apr 2008 22:59:56 +0100 (BST)
User-agent: Alpine 1.00 (DEB 882 2007-12-20)

On Sun, 27 Apr 2008, Tony Abou-Assaleh wrote:

I was thinking more of providing 2 options, so the user can tell grep what kind of compression we use.

That's of little use: it only solves the case where you're using a large number of files compressed with the same compressor. If you're only using one file you can just decompress it into grep, and if you're using mixed compression schemes, it doesn't help.

Having said that, I've thought of another option, though it's possibly politically awkward, and that is to use libmagic (from file) to find out what sort of file you're looking at when in transparent decompression mode. The correct decompressor could then be selected, and others (e.g. liblzo) added as desired without complicating the code or needing any one compression library to recognise all the different types.

--
http://rrt.sc3d.org/ | fantasize, a.  as big as fizzy orange




reply via email to

[Prev in Thread] Current Thread [Next in Thread]