Archive-Unzip-Burst

 view release on metacpan or  search on metacpan

unzip-6.0/man/unzip.1  view on Meta::CPAN

extracted directories are left at the current time.  To enable restoration
of directory timestamps, the negated option \fB\--D\fP should be specified.
On VMS, the option \fB\-D\fP disables timestamp restoration for all extracted
Zip archive items.  (Here, a single \fB\-D\fP on the command line combines
with the default \fB\-D\fP to do what an explicit \fB\-DD\fP does on other
systems.)
.TP
.B \-E
[MacOS only] display contents of MacOS extra field during restore operation.
.TP
.B \-F
[Acorn only] suppress removal of NFS filetype extension from stored filenames.
.TP
.B \-F
[non-Acorn systems supporting long filenames with embedded commas,
and only if compiled with ACORN_FTYPE_NFS defined] translate
filetype information from ACORN RISC OS extra field blocks into a
NFS filetype extension and append it to the names of the extracted files.
(When the stored filename appears to already have an appended NFS filetype
extension, it is replaced by the info from the extra field.)
.TP
.B \-i
[MacOS only] ignore filenames stored in MacOS extra fields. Instead, the
most compatible filename stored in the generic part of the entry's header
is used.
.TP
.B \-j
junk paths.  The archive's directory structure is not recreated; all files
are deposited in the extraction directory (by default, the current one).
.TP
.B \-J
[BeOS only] junk file attributes.  The file's BeOS file attributes are not
restored, just the file's data.
.TP
.B \-J
[MacOS only] ignore MacOS extra fields.  All Macintosh specific info
is skipped. Data-fork and resource-fork are restored as separate files.
.TP
.B \-K
[AtheOS, BeOS, Unix only] retain SUID/SGID/Tacky file attributes.  Without
this flag, these attribute bits are cleared for security reasons.
.TP
.B \-L
convert to lowercase any filename originating on an uppercase-only operating
system or file system.  (This was \fIunzip\fP's default behavior in releases
prior to 5.11; the new default behavior is identical to the old behavior with
the \fB\-U\fP option, which is now obsolete and will be removed in a future
release.)  Depending on the archiver, files archived under single-case
file systems (VMS, old MS-DOS FAT, etc.) may be stored as all-uppercase names;
this can be ugly or inconvenient when extracting to a case-preserving
file system such as OS/2 HPFS or a case-sensitive one such as under
Unix.  By default \fIunzip\fP lists and extracts such filenames exactly as
they're stored (excepting truncation, conversion of unsupported characters,
etc.); this option causes the names of all files from certain systems to be
converted to lowercase.  The \fB\-LL\fP option forces conversion of every
filename to lowercase, regardless of the originating file system.
.TP
.B \-M
pipe all output through an internal pager similar to the Unix \fImore\fP(1)
command.  At the end of a screenful of output, \fIunzip\fP pauses with a
``\-\-More\-\-'' prompt; the next screenful may be viewed by pressing the
Enter (Return) key or the space bar.  \fIunzip\fP can be terminated by
pressing the ``q'' key and, on some systems, the Enter/Return key.  Unlike
Unix \fImore\fP(1), there is no forward-searching or editing capability.
Also, \fIunzip\fP doesn't notice if long lines wrap at the edge of the screen,
effectively resulting in the printing of two or more lines and the likelihood
that some text will scroll off the top of the screen before being viewed.
On some systems the number of available lines on the screen is not detected,
in which case \fIunzip\fP assumes the height is 24 lines.
.TP
.B \-n
never overwrite existing files.  If a file already exists, skip the extraction
of that file without prompting.  By default \fIunzip\fP queries before
extracting any file that already exists; the user may choose to overwrite
only the current file, overwrite all files, skip extraction of the current
file, skip extraction of all existing files, or rename the current file.
.TP
.B \-N
[Amiga] extract file comments as Amiga filenotes.  File comments are created
with the \-c option of \fIzip\fP(1L), or with the \-N option of the Amiga port
of \fIzip\fP(1L), which stores filenotes as comments.
.TP
.B \-o
overwrite existing files without prompting.  This is a dangerous option, so
use it with care.  (It is often used with \fB\-f\fP, however, and is the only
way to overwrite directory EAs under OS/2.)
.IP \fB\-P\fP\ \fIpassword\fP
use \fIpassword\fP to decrypt encrypted zipfile entries (if any).  \fBTHIS IS
INSECURE!\fP  Many multi-user operating systems provide ways for any user to
see the current command line of any other user; even on stand-alone systems
there is always the threat of over-the-shoulder peeking.  Storing the plaintext
password as part of a command line in an automated script is even worse.
Whenever possible, use the non-echoing, interactive prompt to enter passwords.
(And where security is truly important, use strong encryption such as Pretty
Good Privacy instead of the relatively weak encryption provided by standard
zipfile utilities.)
.TP
.B \-q
perform operations quietly (\fB\-qq\fP = even quieter).  Ordinarily \fIunzip\fP
prints the names of the files it's extracting or testing, the extraction
methods, any file or zipfile comments that may be stored in the archive,
and possibly a summary when finished with each archive.  The \fB\-q\fP[\fBq\fP]
options suppress the printing of some or all of these messages.
.TP
.B \-s
[OS/2, NT, MS-DOS] convert spaces in filenames to underscores.  Since all PC
operating systems allow spaces in filenames, \fIunzip\fP by default extracts
filenames with spaces intact (e.g., ``\fCEA\ DATA.\ SF\fR'').  This can be
awkward, however, since MS-DOS in particular does not gracefully support
spaces in filenames.  Conversion of spaces to underscores can eliminate the
awkwardness in some cases.
.TP
.B \-S
[VMS] convert text files (\fB\-a\fP, \fB\-aa\fP) into Stream_LF record format,
instead of the text-file default, variable-length record format.
(Stream_LF is the default record format of VMS \fIunzip\fP. It is applied
unless conversion (\fB\-a\fP, \fB\-aa\fP and/or \fB\-b\fP, \fB\-bb\fP) is
requested or a VMS-specific entry is processed.)
.TP
.B \-U
[UNICODE_SUPPORT only] modify or disable UTF-8 handling.
When UNICODE_SUPPORT is available, the option \fB\-U\fP forces \fIunzip\fP
to escape all non-ASCII characters from UTF-8 coded filenames as ``#Uxxxx''
(for UCS-2 characters, or ``#Lxxxxxx'' for unicode codepoints needing 3
octets).  This option is mainly provided for debugging purpose when the
fairly new UTF-8 support is suspected to mangle up extracted filenames.
.IP
The option \fB\-UU\fP allows to entirely disable the recognition of UTF-8
encoded filenames.  The handling of filename codings within \fIunzip\fP falls
back to the behaviour of previous versions.
.IP
[old, obsolete usage] leave filenames uppercase if
created under MS-DOS, VMS, etc.  See \fB\-L\fP above.
.TP
.B \-V
retain (VMS) file version numbers.  VMS files can be stored with a version
number, in the format \fCfile.ext;##\fR.  By default the ``\fC;##\fR'' version
numbers are stripped, but this option allows them to be retained.  (On
file systems that limit filenames to particularly short lengths, the version
numbers may be truncated or stripped regardless of this option.)
.TP
.B \-W
[only when WILD_STOP_AT_DIR compile-time option enabled]
modifies the pattern matching routine so that both `?' (single-char wildcard)
and `*' (multi-char wildcard) do not match the directory separator character
`/'.  (The two-character sequence ``**'' acts as a multi-char wildcard that
includes the directory separator in its matched characters.)  Examples:
.PP
.EX
    "*.c" matches "foo.c" but not "mydir/foo.c"
    "**.c" matches both "foo.c" and "mydir/foo.c"
    "*/*.c" matches "bar/foo.c" but not "baz/bar/foo.c"
    "??*/*" matches "ab/foo" and "abc/foo"

unzip-6.0/man/unzip.1  view on Meta::CPAN

command-line options, except that they are effectively the first options
on the command line.  To override an environment option, one may use the
``minus operator'' to remove it.  For instance, to override one of the
quiet-flags in the example above, use the command
.PP
.EX
unzip \-\-q[\fIother options\fP] zipfile
.EE
.PP
The first hyphen is the normal
switch character, and the second is a minus sign, acting on the q option.
Thus the effect here is to cancel one quantum of quietness.  To cancel
both quiet flags, two (or more) minuses may be used:
.PP
.EX
unzip \-t\-\-q zipfile
unzip \-\-\-qt zipfile
.EE
.PP
(the two are equivalent).  This may seem awkward
or confusing, but it is reasonably intuitive:  just ignore the first
hyphen and go from there.  It is also consistent with the behavior of
Unix \fInice\fP(1).
.PP
As suggested by the examples above, the default variable names are UNZIP_OPTS
for VMS (where the symbol used to install \fIunzip\fP as a foreign command
would otherwise be confused with the environment variable), and UNZIP
for all other operating systems.  For compatibility with \fIzip\fP(1L),
UNZIPOPT is also accepted (don't ask).  If both UNZIP and UNZIPOPT
are defined, however, UNZIP takes precedence.  \fIunzip\fP's diagnostic
option (\fB\-v\fP with no zipfile name) can be used to check the values
of all four possible \fIunzip\fP and \fIzipinfo\fP environment variables.
.PP
The timezone variable (TZ) should be set according to the local timezone
in order for the \fB\-f\fP and \fB\-u\fP to operate correctly.  See the
description of \fB\-f\fP above for details.  This variable may also be
necessary to get timestamps of extracted files to be set correctly.
The WIN32 (Win9x/ME/NT4/2K/XP/2K3) port of \fIunzip\fP gets the timezone
configuration from the registry, assuming it is correctly set in the
Control Panel.  The TZ variable is ignored for this port.
.PD
.\" =========================================================================
.SH DECRYPTION
Encrypted archives are fully supported by Info-ZIP software, but due to
United States export restrictions, de-/encryption support might be disabled
in your compiled binary.  However, since spring 2000, US export restrictions
have been liberated, and our source archives do now include full crypt code.
In case you need binary distributions with crypt support enabled, see the
file ``WHERE'' in any Info-ZIP source or binary distribution for locations
both inside and outside the US.
.PP
Some compiled versions of \fIunzip\fP may not support decryption.
To check a version for crypt support, either attempt to test or extract
an encrypted archive, or else check \fIunzip\fP's diagnostic
screen (see the \fB\-v\fP option above) for ``\fC[decryption]\fR'' as one
of the special compilation options.
.PP
As noted above, the \fB\-P\fP option may be used to supply a password on
the command line, but at a cost in security.  The preferred decryption
method is simply to extract normally; if a zipfile member is encrypted,
\fIunzip\fP will prompt for the password without echoing what is typed.
\fIunzip\fP continues to use the same password as long as it appears to be
valid, by testing a 12-byte header on each file.  The correct password will
always check out against the header, but there is a 1-in-256 chance that an
incorrect password will as well.  (This is a security feature of the PKWARE
zipfile format; it helps prevent brute-force attacks that might otherwise
gain a large speed advantage by testing only the header.)  In the case that
an incorrect password is given but it passes the header test anyway, either
an incorrect CRC will be generated for the extracted data or else \fIunzip\fP
will fail during the extraction because the ``decrypted'' bytes do not
constitute a valid compressed data stream.
.PP
If the first password fails the header check on some file, \fIunzip\fP will
prompt for another password, and so on until all files are extracted.  If
a password is not known, entering a null password (that is, just a carriage
return or ``Enter'') is taken as a signal to skip all further prompting.
Only unencrypted files in the archive(s) will thereafter be extracted.  (In
fact, that's not quite true; older versions of \fIzip\fP(1L) and
\fIzipcloak\fP(1L) allowed null passwords, so \fIunzip\fP checks each encrypted
file to see if the null password works.  This may result in ``false positives''
and extraction errors, as noted above.)
.PP
Archives encrypted with 8-bit passwords (for example, passwords with accented
European characters) may not be portable across systems and/or other
archivers.  This problem stems from the use of multiple encoding methods for
such characters, including Latin-1 (ISO 8859-1) and OEM code page 850.
DOS \fIPKZIP\fP 2.04g uses the OEM code page; Windows \fIPKZIP\fP 2.50
uses Latin-1 (and is therefore incompatible with DOS \fIPKZIP\fP); Info-ZIP
uses the OEM code page on DOS, OS/2 and Win3.x ports but ISO coding
(Latin-1 etc.) everywhere else; and Nico Mak's \fIWinZip\fP 6.x does not
allow 8-bit passwords at all.  \fIUnZip\fP 5.3 (or newer) attempts to use
the default character set first (e.g., Latin-1), followed by the alternate
one (e.g., OEM code page) to test passwords.  On EBCDIC systems, if both
of these fail, EBCDIC encoding will be tested as a last resort.  (EBCDIC is
not tested on non-EBCDIC systems, because there are no known archivers
that encrypt using EBCDIC encoding.)  ISO character encodings other than
Latin-1 are not supported.  The new addition of (partially) Unicode (resp.
UTF-8) support in \fIUnZip\fP 6.0 has not yet been adapted to the encryption
password handling in \fIunzip\fP.  On systems that use UTF-8 as native
character encoding, \fIunzip\fP simply tries decryption with the native
UTF-8 encoded password; the built-in attempts to check the password in
translated encoding have not yet been adapted for UTF-8 support and
will consequently fail.
.PD
.\" =========================================================================
.SH EXAMPLES
To use \fIunzip\fP to extract all members of the archive \fIletters.zip\fP
into the current directory and subdirectories below it, creating any
subdirectories as necessary:
.PP
.EX
unzip letters
.EE
.PP
To extract all members of \fIletters.zip\fP into the current directory only:
.PP
.EX
unzip -j letters
.EE
.PP
To test \fIletters.zip\fP, printing only a summary message indicating
whether the archive is OK or not:
.PP
.EX
unzip -tq letters
.EE
.PP
To test \fIall\fP zipfiles in the current directory, printing only the
summaries:
.PP
.EX
unzip -tq \e*.zip
.EE
.PP
(The backslash before the asterisk is only required if the shell expands
wildcards, as in Unix; double quotes could have been used instead, as in



( run in 1.266 second using v1.01-cache-2.11-cpan-6aa56a78535 )