bug-tar
[Top][All Lists]
Advanced

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

[Bug-tar] maybe need for clarification: --unlink-first vs. default opera


From: Helmut Waitzmann
Subject: [Bug-tar] maybe need for clarification: --unlink-first vs. default operation when extracting files
Date: Wed, 25 May 2005 11:03:45 +0200
User-agent: Gnus/5.1006 (Gnus v5.10.6) Emacs/21.3 (gnu/linux)

Quoting the manual

      When extracting files, if `tar' discovers that the extracted file
   already exists, it normally replaces the file by removing it before
   extracting it, to prevent confusion in the presence of hard or
   symbolic links.  (If the existing file is a symbolic link, it is
   removed, not followed.)  However, if a directory cannot be removed
   because it is nonempty, `tar' neither removes it nor modifies its
   ownership, permissions, or time stamps.

I guess, that tar removes a file which is to be replaced by an archive
member before extracting, right?

Then I cannot see any difference to

      Finally, the `--unlink-first' (`-U') option can improve performance
   in some cases by causing `tar' to remove files unconditionally before
   extracting them.

`--unlink-first'
`-U'
     Directs `tar' to remove the corresponding file from the file
     system before extracting it from the archive.  *Note Writing::.

So, what's the purpose of the '--unlink-first' option?  What does
"unconditionally" mean in this context?

As far as I understand the default operation when extracting, there are
no circumstances under which tar would not unlink a file prior to
extracting the archive member (unless the '--overwrite' option is
supplied, of cause).

Could somebody please clarify that to me?
-- 
Wenn Sie mir E-Mail schreiben, stellen |  When writing me e-mail, please
Sie bitte vor meine E-Mail-Adresse     |  precede my e-mail address with
meinen Vor- und Nachnamen, etwa so:    |  my full name, like
Helmut Waitzmann <address@hidden>, (Helmut Waitzmann) address@hidden




reply via email to

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