bug-coreutils
[Top][All Lists]
Advanced

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

Re: [PATCH] add new sort option --xargs (-x)


From: Bo Borgerson
Subject: Re: [PATCH] add new sort option --xargs (-x)
Date: Thu, 3 Apr 2008 15:12:26 -0400

On Thu, Apr 3, 2008 at 2:05 PM, Jim Meyering <address@hidden> wrote:
 >  Sounds interesting.
 >  I suppose it can work with an arbitrary decompressor?
 >
 >  Note this relatively new option:
 >
 >       --compress-program=PROG  compress temporaries with PROG;
 >                               decompress them with PROG -d
 >

 Yep.

 My current convention is:

  --magic-open=PROG[,PROG]...

 So if you want to merge a gzip'd file with a bzip2'd file you can use
 --magic-open=gzip,bzip2 (or just --magic-open, which enables all).

 For each regular file it checks magic and if it looks like a type that
 can be handled by one of PROG it opens a PROG -d -c -f (the -f is just
 in case the magic was a false-positive).

 Of course this re-introduces findprog into sort (for find_in_path),
 which may not be desirable.  A convention more similar to that used
 for --compress-program would eliminate this (and the magic-checking),
 but limit a given merge to files compressed with a single program.

 Bo




reply via email to

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