bug-tar
[Top][All Lists]
Advanced

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

Re: [Bug-tar] option -C ignored when it comes after the source directory


From: Sergey Poznyakoff
Subject: Re: [Bug-tar] option -C ignored when it comes after the source directory
Date: Sat, 15 May 2010 09:56:25 +0300

Bruno Haible <address@hidden> ha escrit:

> The bug exists, whether I use the dashed form or the dashless form:
>    $ tar -c -v -f - . -C /mnt > /dev/null
> ignores the -C option.

It does not ignore it. It is simply useless in this form (with no
arguments following it). The -C option affects all other options
and arguments that follow it, up to the next -C option or end
of command line, whichever occurs first. This is important for
certain tar operations. Consider, for example, this:

  tar -cf arc.tar -C /usr/src dir -C /etc default

The resulting archive will then contain directories `dir' and `default'
(and files in them) without the leading directory components.

Regards,
Sergey



reply via email to

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