b.n. <[EMAIL PROTECTED]> wrote:

> Alexander Skwar ha scritto:
>> Stroller <[EMAIL PROTECTED]> wrote:
>> 
>>> On 24 Sep 2007, at 09:30, Alexander Skwar wrote:
>>>> ...
>>>>> and if p7zip supports pipes, you don't need its support in tar.
>>>>> Just pipe
>>>>> from/to it.
>>>> It does and that's the way it's supposed to be used on unix, according
>>>> to its manpage.
>>> GNU tar features the -j, -z and -Z options.
>> 
>> Yes, bad, isn't it? These options are not part of the Posix standard.
>> It would be good, if these superflous options wouldn't be present at
>> all. I say "superflous", as pipes work just fine.
> 
> It's not that an option becomes "bad" just because it's not carved into
> the POSIX standard.

To a degree, it is.

> What's important, I guess, is that tar is  
> POSIX-compliant, so that if you want, you can build POSIX-compliant
> scripts etc. ,

Depends. On the hand, you're right. But if non-compliant options
exist, people tend to use them. That's bad in so far, as they get
used to non-standard behaviour. That's especially bad, as standard
compliants solution exist.

> but I can't see how non-POSIX but handy extensions could 
> be bad. 

Let me give you a different example, although it has nothing
to do with POSIX.

Internet Explorer translates a \ in a URL to /. That's a non
standard compliant behaviour. Now, as many people (still *G*)
use IE, many people rely on that mis-behaviour of IE and make
it hard for non-misbehaving browsers (ie. Mozilla) to display
the content.

What does this have to do with GNU tar and it adding superflous
options? Quite a lot. -j et.al. are non-standard options. If a
(badly written) script relies on the presence of -j, this script
won't work with a POSIX compliant tar (like star or any Unix
tar (eg. Sun, HP, ...)). Is that bad? Yes, it is. It is bad, as
there's an easily accessible solution to this problem available:
Use pipes! In this case, the solution would be: 

        tar cf - dir | bzip2 > dir.tar.bz2
        tar cf - dir | 7z a -si dir.tar.7z

Or for decompression:

        bzcat dir.tar.bz2 | tar xf -
        7z x -so dir.tar.7z | tar xf -

> Maybe it's me not seeing the problem.

Yep.

> Maybe the POSIX standard  
> could just be extended as well. :)

Equally fine.

>>> and it would be nice to see p7zip supported
>>> in the same way.
>> 
>> No.
> 
> "No" means nothing. Tell us why.

Pipes exist. The current "integration" of 7-zip is fine. There's
no need to integrate other compression into tar. Actually, there's
no need at all to integrate ANY compression alg. into tar.

Furthermore, especially with 7zip, an integration into tar would
make the use of 7zip somewhat limited, as all of the additional
command line options of 7z would not be accessible anymore.

Alexander Skwar

-- 
[EMAIL PROTECTED] mailing list

Reply via email to