[Top][All Lists]

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

Re: [Gnu-arch-users] Pipes?

From: Phil Richards
Subject: Re: [Gnu-arch-users] Pipes?
Date: Fri, 19 Mar 2004 09:40:09 +0000 (GMT)

On Wed, 17 Mar 2004 16:42:54 -0700, Pierce T. Wetter III wrote:
>>>   Actually, I was thinking it might be a global option. Early on in
>>> main(), it would
>>> look for a --pipe option, and if it found one, append stdin to argv
>>> before doing anything else.
[Tom Lord replied:]
>> Nah.  You want --list or --file for arguments of a particular type.
[Pierce said:]
>   I'd understand that better with an example of each.

I think what Tom is getting at is that --pipe is unnecessarily restricted
to a single use.  I agree.  It would be much better to be able to do
(using the tar-option):

tla ... --files-from=blah --files-from=wah justafilebyitself

--pipe would be replaced by the more "expected" --files-from=-, and could
be combined with all the other uses.

(I use "--files-from" rather than "--file" because it (a) is what tar
uses; and (b) reads better to my eye, but "--file" or "--files" is fine.)

On the "what escape style should be used", well, frankly, I'd
say "let the user choose".  For any command that can output a list(?) of
files, allow an option "--file-name-quote-style=" (as a bad example) which
takes a value of "0", "pika", "shell", etc.

Yes, it's dodging the issue somewhat - there are clear advantages to a
bullet-proof solution, but there are lots of commands out there that won't
work with Pika style quoting, but will with null-termination.  This allows
both camps to be happy (and doesn't, I expect, have a major coding

There is precedence for this approach - find, xargs, and tar all support
something similar.

change name before "@" to "phil" for email

reply via email to

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