📄 unzip.txt
字号:
unzip --ql file.zip or unzip -l-q file.zip or unzip -l--q file.zip (Extra minuses in options don't hurt.)TIPS The current maintainer, being a lazy sort, finds it very useful to define a pair of aliases: tt for ``unzip -tq'' and ii for ``unzip -Z'' (or ``zipinfo''). One may then simply type ``tt zipfile'' to test an archive, something that is worth making a habit of doing. With luck unzip will report ``No errors detected in compressed data of zipfile.zip,'' after which one may breathe a sigh ofInfo-ZIP 28 February 2005 (v5.52) 14UNZIP(1L) UNZIP(1L) relief. The maintainer also finds it useful to set the UNZIP envi- ronment variable to ``-aL'' and is tempted to add ``-C'' as well. His ZIPINFO variable is set to ``-z''.DIAGNOSTICS The exit status (or error level) approximates the exit codes defined by PKWARE and takes on the following values, except under VMS: 0 normal; no errors or warnings detected. 1 one or more warning errors were encountered, but processing completed successfully any- way. This includes zipfiles where one or more files was skipped due to unsupported compression method or encryption with an unknown password. 2 a generic error in the zipfile format was detected. Processing may have completed successfully anyway; some broken zipfiles created by other archivers have simple work- arounds. 3 a severe error in the zipfile format was detected. Processing probably failed imme- diately. 4 unzip was unable to allocate memory for one or more buffers during program initializa- tion. 5 unzip was unable to allocate memory or unable to obtain a tty to read the decryp- tion password(s). 6 unzip was unable to allocate memory during decompression to disk. 7 unzip was unable to allocate memory during in-memory decompression. 8 [currently not used] 9 the specified zipfiles were not found. 10 invalid options were specified on the com- mand line. 11 no matching files were found. 50 the disk is (or was) full during extraction.Info-ZIP 28 February 2005 (v5.52) 15UNZIP(1L) UNZIP(1L) 51 the end of the ZIP archive was encountered prematurely. 80 the user aborted unzip prematurely with con- trol-C (or similar) 81 testing or extraction of one or more files failed due to unsupported compression meth- ods or unsupported decryption. 82 no files were found due to bad decryption password(s). (If even one file is success- fully processed, however, the exit status is 1.) VMS interprets standard Unix (or PC) return values as other, scarier-looking things, so unzip instead maps them into VMS-style status codes. The current mapping is as follows: 1 (success) for normal exit, 0x7fff0001 for warning errors, and (0x7fff000? + 16*nor- mal_unzip_exit_status) for all other errors, where the `?' is 2 (error) for unzip values 2, 9-11 and 80-82, and 4 (fatal error) for the remaining ones (3-8, 50, 51). In addition, there is a compilation option to expand upon this behavior: defining RETURN_CODES results in a human- readable explanation of what the error status means.BUGS Multi-part archives are not yet supported, except in con- junction with zip. (All parts must be concatenated together in order, and then ``zip -F'' must be performed on the concatenated archive in order to ``fix'' it.) This will definitely be corrected in the next major release. Archives read from standard input are not yet supported, except with funzip (and then only the first member of the archive can be extracted). Archives encrypted with 8-bit passwords (e.g., passwords with accented European characters) may not be portable across systems and/or other archivers. See the discussion in DECRYPTION above. unzip's -M (``more'') option tries to take into account automatic wrapping of long lines. However, the code may fail to detect the correct wrapping locations. First, TAB characters (and similar control sequences) are not taken into account, they are handled as ordinary printable char- acters. Second, depending on the actual system / OS port, unzip may not detect the true screen geometry but rather rely on "commonly used" default dimensions. The correct handling of tabs would require the implementation of a query for the actual tabulator setup on the output con- sole.Info-ZIP 28 February 2005 (v5.52) 16UNZIP(1L) UNZIP(1L) Dates, times and permissions of stored directories are not restored except under Unix. (On Windows NT and successors, timestamps are now restored.) [MS-DOS] When extracting or testing files from an archive on a defective floppy diskette, if the ``Fail'' option is chosen from DOS's ``Abort, Retry, Fail?'' message, older versions of unzip may hang the system, requiring a reboot. This problem appears to be fixed, but control-C (or con- trol-Break) can still be used to terminate unzip. Under DEC Ultrix, unzip would sometimes fail on long zip- files (bad CRC, not always reproducible). This was appar- ently due either to a hardware bug (cache memory) or an operating system bug (improper handling of page faults?). Since Ultrix has been abandoned in favor of Digital Unix (OSF/1), this may not be an issue anymore. [Unix] Unix special files such as FIFO buffers (named pipes), block devices and character devices are not restored even if they are somehow represented in the zip- file, nor are hard-linked files relinked. Basically the only file types restored by unzip are regular files, directories and symbolic (soft) links. [OS/2] Extended attributes for existing directories are only updated if the -o (``overwrite all'') option is given. This is a limitation of the operating system; because directories only have a creation time associated with them, unzip has no way to determine whether the stored attributes are newer or older than those on disk. In practice this may mean a two-pass approach is required: first unpack the archive normally (with or without fresh- ening/updating existing files), then overwrite just the directory entries (e.g., ``unzip -o foo */''). [VMS] When extracting to another directory, only the [.foo] syntax is accepted for the -d option; the simple Unix foo syntax is silently ignored (as is the less common VMS foo.dir syntax). [VMS] When the file being extracted already exists, unzip's query only allows skipping, overwriting or renam- ing; there should additionally be a choice for creating a new version of the file. In fact, the ``overwrite'' choice does create a new version; the old version is not overwritten or deleted.SEE ALSO funzip(1L), zip(1L), zipcloak(1L), zipgrep(1L), zip- info(1L), zipnote(1L), zipsplit(1L)URL The Info-ZIP home page is currently atInfo-ZIP 28 February 2005 (v5.52) 17UNZIP(1L) UNZIP(1L) http://www.info-zip.org/pub/infozip/ or ftp://ftp.info-zip.org/pub/infozip/ .AUTHORS The primary Info-ZIP authors (current semi-active members of the Zip-Bugs workgroup) are: Ed Gordon (Zip, general maintenance, shared code, Zip64, Win32, Unix); Christian Spieler (UnZip maintenance coordination, VMS, MS-DOS, Win32, shared code, general Zip and UnZip integration and optimization); Onno van der Linden (Zip); Mike White (Win32, Windows GUI, Windows DLLs); Kai Uwe Rommel (OS/2, Win32); Steven M. Schweda (VMS, support of new features); Paul Kienitz (Amiga, Win32); Chris Herborth (BeOS, QNX, Atari); Jonathan Hudson (SMS/QDOS); Sergio Monesi (Acorn RISC OS); Harald Denker (Atari, MVS); John Bush (Solaris, Amiga); Hunter Goatley (VMS, Info-ZIP Site maintenance); Steve Salisbury (Win32); Steve Miller (Windows CE GUI), Johnny Lee (MS-DOS, Win32, Zip64); and Dave Smith (Tandem NSK). The following people were former members of the Info-ZIP development group and provided major contributions to key parts of the current code: Greg ``Cave Newt'' Roelofs (UnZip, unshrink decompression); Jean-loup Gailly (deflate compression); Mark Adler (inflate decompression, fUnZip). The author of the original unzip code upon which Info- ZIP's was based is Samuel H. Smith; Carl Mascott did the first Unix port; and David P. Kirschbaum organized and led Info-ZIP in its early days with Keith Petersen hosting the original mailing list at WSMR-SimTel20. The full list of contributors to UnZip has grown quite large; please refer to the CONTRIBS file in the UnZip source distribu- tion for a relatively complete version.VERSIONS v1.2 15 Mar 89 Samuel H. Smith v2.0 9 Sep 89 Samuel H. Smith v2.x fall 1989 many Usenet contributors v3.0 1 May 90 Info-ZIP (DPK, consolidator) v3.1 15 Aug 90 Info-ZIP (DPK, consolidator) v4.0 1 Dec 90 Info-ZIP (GRR, maintainer) v4.1 12 May 91 Info-ZIP v4.2 20 Mar 92 Info-ZIP (Zip-Bugs subgroup, GRR) v5.0 21 Aug 92 Info-ZIP (Zip-Bugs subgroup, GRR) v5.01 15 Jan 93 Info-ZIP (Zip-Bugs subgroup, GRR) v5.1 7 Feb 94 Info-ZIP (Zip-Bugs subgroup, GRR) v5.11 2 Aug 94 Info-ZIP (Zip-Bugs subgroup, GRR) v5.12 28 Aug 94 Info-ZIP (Zip-Bugs subgroup, GRR) v5.2 30 Apr 96 Info-ZIP (Zip-Bugs subgroup, GRR) v5.3 22 Apr 97 Info-ZIP (Zip-Bugs subgroup, GRR) v5.31 31 May 97 Info-ZIP (Zip-Bugs subgroup, GRR) v5.32 3 Nov 97 Info-ZIP (Zip-Bugs subgroup, GRR)Info-ZIP 28 February 2005 (v5.52) 18UNZIP(1L) UNZIP(1L) v5.4 28 Nov 98 Info-ZIP (Zip-Bugs subgroup, SPC) v5.41 16 Apr 00 Info-ZIP (Zip-Bugs subgroup, SPC) v5.42 14 Jan 01 Info-ZIP (Zip-Bugs subgroup, SPC) v5.5 17 Feb 02 Info-ZIP (Zip-Bugs subgroup, SPC) v5.51 22 May 04 Info-ZIP (Zip-Bugs subgroup, SPC) v5.52 28 Feb 05 Info-ZIP (Zip-Bugs subgroup, SPC)Info-ZIP 28 February 2005 (v5.52) 19
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -