Macos Unzip Command Line



Since macOS is based on Unix there are a number of ways to compress files and folders within the filing system using Unix based application code, below are a few options using the Terminal or command line interface (cli). The default command line application interface in macOS is the Terminal and is stored in /Applications/Utilities.

Unzip filename1.zip filename2.zip filename3.zip will unzip multiple files. You can use this with as many zip files as you want, and it’s a lot quicker than doing this in an FTP client. Tar – Create and Unpack Compressed Archives. The tar command will let you create and unpack.tar.gz archives, which is an alternative to using.zip archives. Running this command will add your authtoken to your ngrok.yml file. Connecting an account will list your open tunnels in the dashboard, give you longer tunnel timeouts, and more. Visit the dashboard to get your auth token.

File and folder compression saves on file size and ensures the contents are captured and delivered or stored as one monolithic file. A compressed file which contains files and folders is generally referred to as an archive. Here are some built-in compression applications you can use including zip, tar, gz, bz2, gz and dmg.

ZIP – Cross Platform

First up is ZIP one of the most commonly used compression techniques used across all platforms

To compress

To extract

If you want to make a zip without those invisible Mac resource files such as “_MACOSX” or “._Filename” and .ds store files, use the “-X” option in the command so:

TAR.GZ – Cross Platform

Second up is TAR, an old favorite on Unix/Linux – you add the GZ for the compression – compresses tighter than zip

To compress

To extract

TAR.BZ2 – Cross Platform

A variation on TAR GZ but with better compression than both tar.gz and zip.

To compress

To extract

GZ

Without the tar

To extract

DMG – macOS Only

This one is macOSnative only – for a GUI interface use /Applications/Utilities/Disk Utility – for command line use:

To create

To mount

To view

To Eject

You can also use a number of different formats for creating a .dmg

  • UDZO – Compressed image (default)
  • UDRO – Read-only image
  • UDBZ – Better compressed image
  • UDRW – Read/Write image
  • UDTO – DVD disk image

That’s the low down, the more common compression packages available will typically be covered in one of the above.

Name

unzip - list, test and extract compressed files in a ZIP archive

Synopsis

unzip [-Z] [-cflptTuvz[abjnoqsCDKLMUVWX$/:^]] file[.zip] [file(s) ...] [-xxfile(s) ...][-dexdir]

Description

unzip will list, test, or extract files from a ZIP archive, commonly found on MS-DOS systems. The default behavior (with no options) is to extractinto the current directory (and subdirectories below it) all files from the specified ZIP archive. A companion program, zip(1L), creates ZIP archives;both programs are compatible with archives created by PKWARE's PKZIP and PKUNZIP for MS-DOS, but in many cases the program options or defaultbehaviors differ.

Arguments

file[.zip]

Path of the ZIP archive(s). If the file specification is a wildcard, each matching file is processed in an order determined by the operating system (or filesystem). Only the filename can be a wildcard; the path itself cannot. Wildcard expressions are similar to those supported in commonly used Unix shells(sh, ksh, csh) and may contain:
*

matches a sequence of 0 or more characters

?

matches exactly 1 character

[...]

matches any single character found inside the brackets; ranges are specified by a beginning character, a hyphen, and an ending character. If an exclamationpoint or a caret ('!' or '^') follows the left bracket, then the range of characters within the brackets is complemented (that is, anything except thecharacters inside the brackets is considered a match). To specify a verbatim left bracket, the three-character sequence '[[]' has to be used.

(Be sure to quote any character that might otherwise be interpreted or modified by the operating system, particularly under Unix and VMS.) If no matches arefound, the specification is assumed to be a literal filename; and if that also fails, the suffix .zip is appended. Note that self-extracting ZIP filesare supported, as with any other ZIP archive; just specify the .exe suffix (if any) explicitly.
[file(s)]
An optional list of archive members to be processed, separated by spaces. (VMS versions compiled with VMSCLI defined must delimit files with commas instead.See -v in OPTIONS below.) Regular expressions (wildcards) may be used to match multiple members; see above. Again, be sure to quote expressionsthat would otherwise be expanded or modified by the operating system.
[-xxfile(s)]
An optional list of archive members to be excluded from processing. Since wildcard characters normally match ('/') directory separators (for exceptions seethe option -W), this option may be used to exclude any files that are in subdirectories. For example, 'unzip foo *.[ch] -x */*' would extractall C source files in the main directory, but none in any subdirectories. Without the -x option, all C source files in all directories within thezipfile would be extracted.
[-dexdir]
An optional directory to which to extract files. By default, all files and subdirectories are recreated in the current directory; the -d optionallows extraction in an arbitrary directory (always assuming one has permission to write to the directory). This option need not appear at the end of thecommand line; it is also accepted before the zipfile specification (with the normal options), immediately after the zipfile specification, or between thefile(s) and the -x option. The option and directory may be concatenated without any white space between them, but note that this may cause normalshell behavior to be suppressed. In particular, '-d ~' (tilde) is expanded by Unix C shells into the name of the user's home directory, but'-d~' is treated as a literal subdirectory '~' of the current directory.

Options

Note that, in order to support obsolescent hardware, unzip's usage screen is limited to 22 or 23 lines and should therefore be considered only areminder of the basic unzip syntax rather than an exhaustive list of all possible flags. The exhaustive list follows:

-Z

zipinfo(1L) mode. If the first option on the command line is -Z, the remaining options are taken to be zipinfo(1L) options. See theappropriate manual page for a description of these options.

-A

[OS/2, Unix DLL] print extended help for the DLL's programming interface (API).

-c

extract files to stdout/screen ('CRT'). This option is similar to the -p option except that the name of each file is printed as it is extracted,the -a option is allowed, and ASCII-EBCDIC conversion is automatically performed if appropriate. This option is not listed in the unzip usagescreen.

-f

freshen existing files, i.e., extract only those files that already exist on disk and that are newer than the disk copies. By default unzip queriesbefore overwriting, but the -o option may be used to suppress the queries. Note that under many operating systems, the TZ (timezone) environmentvariable must be set correctly in order for -f and -u to work properly (under Unix the variable is usually set automatically). The reasons forthis are somewhat subtle but have to do with the differences between DOS-format file times (always local time) and Unix-format times (always in GMT/UTC) andthe necessity to compare the two. A typical TZ value is 'PST8PDT' (US Pacific time with automatic adjustment for Daylight Savings Time or 'summer time').

-l

list archive files (short format). The names, uncompressed file sizes and modification dates and times of the specified files are printed, along with totalsfor all files specified. If UnZip was compiled with OS2_EAS defined, the -l option also lists columns for the sizes of stored OS/2 extended attributes(EAs) and OS/2 access control lists (ACLs). In addition, the zipfile comment and individual file comments (if any) are displayed. If a file was archived from asingle-case file system (for example, the old MS-DOS FAT file system) and the -L option was given, the filename is converted to lowercase and isprefixed with a caret (^).

-p

extract files to pipe (stdout). Nothing but the file data is sent to stdout, and the files are always extracted in binary format, just as they are stored(no conversions).

-t

test archive files. This option extracts each specified file in memory and compares the CRC (cyclic redundancy check, an enhanced checksum) of the expandedfile with the original file's stored CRC value.

-T

[most OSes] set the timestamp on the archive(s) to that of the newest file in each one. This corresponds to zip's -go option except that itcan be used on wildcard zipfiles (e.g., 'unzip -T *.zip') and is much faster.

-u

update existing files and create new ones if needed. This option performs the same function as the -f option, extracting (with query) files that arenewer than those with the same name on disk, and in addition it extracts those files that do not already exist on disk. See -f above for information onsetting the timezone properly.

-v

list archive files (verbose format) or show diagnostic version info. This option has evolved and now behaves as both an option and a modifier. As an optionit has two purposes: when a zipfile is specified with no other options, -v lists archive files verbosely, adding to the basic -l info thecompression method, compressed size, compression ratio and 32-bit CRC. In contrast to most of the competing utilities, unzip removes the 12 additionalheader bytes of encrypted entries from the compressed size numbers. Therefore, compressed size and compression ratio figures are independent of the entry'sencryption status and show the correct compression performance. (The complete size of the encrypted compressed data stream for zipfile entries is reported bythe more verbose zipinfo(1L) reports, see the separate manual.) When no zipfile is specified (that is, the complete command is simply 'unzip-v'), a diagnostic screen is printed. In addition to the normal header with release date and version, unzip lists the home Info-ZIP ftp site andwhere to find a list of other ftp and non-ftp sites; the target operating system for which it was compiled, as well as (possibly) the hardware on which it wascompiled, the compiler and version used, and the compilation date; any special compilation options that might affect the program's operation (see alsoDECRYPTION below); and any options stored in environment variables that might do the same (see ENVIRONMENT OPTIONS below). As a modifier it worksin conjunction with other options (e.g., -t) to produce more verbose or debugging output; this is not yet fully implemented but will be in futurereleases.

-z

display only the archive comment.

Modifiers

-a

convert text files. Ordinarily all files are extracted exactly as they are stored (as 'binary' files). The -a option causes files identified byzip as text files (those with the 't' label in zipinfo listings, rather than 'b') to be automatically extracted as such, converting line endings,end-of-file characters and the character set itself as necessary. (For example, Unix files use line feeds (LFs) for end-of-line (EOL) and have no end-of-file(EOF) marker; Macintoshes use carriage returns (CRs) for EOLs; and most PC operating systems use CR+LF for EOLs and control-Z for EOF. In addition, IBMmainframes and the Michigan Terminal System use EBCDIC rather than the more common ASCII character set, and NT supports Unicode.) Note that zip'sidentification of text files is by no means perfect; some 'text' files may actually be binary and vice versa. unzip therefore prints'[text]' or '[binary]' as a visual check for each file it extracts when using the -a option. The -aa option forces allfiles to be extracted as text, regardless of the supposed file type. On VMS, see also -S.

-b

[general] treat all files as binary (no text conversions). This is a shortcut for ---a.

-b

[Tandem] force the creation files with filecode type 180 ('C') when extracting Zip entries marked as 'text'. (On Tandem, -a is enabled by default,see above).

-b

[VMS] auto-convert binary files (see -a above) to fixed-length, 512-byte record format. Doubling the option (-bb) forces all files to beextracted in this format. When extracting to standard output (-c or -p option in effect), the default conversion of text record delimiters isdisabled for binary (-b) resp. all (-bb) files.

-B

[when compiled with UNIXBACKUP defined] save a backup copy of each overwritten file. The backup file is gets the name of the target file with a tilde andoptionally a unique sequence number (up to 5 digits) appended. The sequence number is applied whenever another file with the original name plus tilde alreadyexists. When used together with the 'overwrite all' option -o, numbered backup files are never created. In this case, all backup files are named as theoriginal file with an appended tilde, existing backup files are deleted without notice. This feature works similarly to the default behavior of emacs(1)in many locations.

Example: the old copy of 'foo' is renamed to 'foo~'.

Warning: Users should be aware that the -B option does not prevent loss of existing data under all circumstances. For example, when unzip isrun in overwrite-all mode, an existing 'foo~' file is deleted before unzip attempts to rename 'foo' to 'foo~'. Whenthis rename attempt fails (because of a file locks, insufficient privileges, or ...), the extraction of 'foo~' gets cancelled, but the old backupfile is already lost. A similar scenario takes place when the sequence number range for numbered backup files gets exhausted (99999, or 65535 for 16-bitsystems). In this case, the backup file with the maximum sequence number is deleted and replaced by the new backup version without notice.

-C

use case-insensitive matching for the selection of archive entries from the command-line list of extract selection patterns. unzip's philosophy is'you get what you ask for' (this is also responsible for the -L/-U change; see the relevant options below). Because some file systems are fullycase-sensitive (notably those under the Unix operating system) and because both ZIP archives and unzip itself are portable across platforms,unzip's default behavior is to match both wildcard and literal filenames case-sensitively. That is, specifying 'makefile' on the command linewill only match 'makefile' in the archive, not 'Makefile' or 'MAKEFILE' (and similarly for wildcard specifications). Since this does notcorrespond to the behavior of many other operating/file systems (for example, OS/2 HPFS, which preserves mixed case but is not sensitive to it), the -Coption may be used to force all filename matches to be case-insensitive. In the example above, all three files would then match 'makefile' (or'make*', or similar). The -C option affects file specs in both the normal file list and the excluded-file list (xlist).

Macos unzip command line installer
Please note that the -C option does neither affect the search for the zipfile(s) nor the matching of archive entries to existing files on theextraction path. On a case-sensitive file system, unzip will never try to overwrite a file 'FOO' when extracting an entry 'foo'!
-D

skip restoration of timestamps for extracted items. Normally, unzip tries to restore all meta-information for extracted items that are supplied inthe Zip archive (and do not require privileges or impose a security risk). By specifying -D, unzip is told to suppress restoration of timestampsfor directories explicitly created from Zip archive entries. This option only applies to ports that support setting timestamps for directories (currentlyATheOS, BeOS, MacOS, OS/2, Unix, VMS, Win32, for other unzip ports, -D has no effect). The duplicated option -DD forces suppression oftimestamp restoration for all extracted entries (files and directories). This option results in setting the timestamps for all extracted entries to the currenttime.

On VMS, the default setting for this option is -D for consistency with the behaviour of BACKUP: file timestamps are restored, timestamps of extracteddirectories are left at the current time. To enable restoration of directory timestamps, the negated option --D should be specified. On VMS, the option-D disables timestamp restoration for all extracted Zip archive items. (Here, a single -D on the command line combines with the default -Dto do what an explicit -DD does on other systems.)
-E

[MacOS only] display contents of MacOS extra field during restore operation.

-F

[Acorn only] suppress removal of NFS filetype extension from stored filenames.

Macos unzip command line options

-F

[non-Acorn systems supporting long filenames with embedded commas, and only if compiled with ACORN_FTYPE_NFS defined] translate filetype information fromACORN 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 alreadyhave an appended NFS filetype extension, it is replaced by the info from the extra field.)

-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.

-j

junk paths. The archive's directory structure is not recreated; all files are deposited in the extraction directory (by default, the current one).

-J

[BeOS only] junk file attributes. The file's BeOS file attributes are not restored, just the file's data.

-J

[MacOS only] ignore MacOS extra fields. All Macintosh specific info is skipped.. Embedded control characters in file names might have nasty side effects when displayedon screen by some listing code without sufficient filtering. And, for ordinary users, it may be difficult to handle such file names (e.g. when trying tospecify it for open, copy, move, or delete operations). Therefore, unzip applies a filter by default that removes potentially dangerous controlcharacters from the extracted file names. The -^ option allows to override this filter in the rare case that embedded filename control characters are tobe intentionally restored.

-2

[VMS] force unconditionally conversion of file names to ODS2-compatible names. The default is to exploit the destination file system, preserving case andextended file name characters on an ODS5 destination file system; and applying the ODS2-compatibility file name filtering on an ODS2 destination filesystem.

Environment Options

unzip's default behavior may be modified via options placed in an environment variable. This can be done with any option, but it is probably mostuseful with the -a, -L, -C, -q, -o, or -n modifiers: make unzip auto-convert text files by default, make itconvert filenames from uppercase systems to lowercase, make it match names case-insensitively, make it quieter, or make it always overwrite or never overwritefiles as it extracts them. For example, to make unzip act as quietly as possible, only reporting errors, one would use one of the followingcommands:

Unix Bourne shell:
UNZIP=-qq; export UNZIP
Unix C shell:
setenv UNZIP -qq
OS/2 or MS-DOS:
set UNZIP=-qq
VMS (quotes for lowercase):

Macos Unzip Command Line Command

define UNZIP_OPTS '-qq'
Environment options are, in effect, considered to be just like any other command-line options, except that they are effectively the first options on thecommand 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 theexample above, use the command
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 ofquietness. To cancel both quiet flags, two (or more) minuses may be used:
(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 alsoconsistent with the behavior of Unix nice(1).

As suggested by the examples above, the default variable names are UNZIP_OPTS for VMS (where the symbol used to install unzip as a foreign commandwould otherwise be confused with the environment variable), and UNZIP for all other operating systems. For compatibility with zip(1L), UNZIPOPT is alsoaccepted (don't ask). If both UNZIP and UNZIPOPT are defined, however, UNZIP takes precedence. unzip's diagnostic option (-v with no zipfilename) can be used to check the values of all four possible unzip and zipinfo environment variables.

The timezone variable (TZ) should be set according to the local timezone in order for the -f and -u to operate correctly. See the descriptionof -f 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 unzip gets the timezone configuration from the registry, assuming it is correctly set in the Control Panel. The TZvariable is ignored for this port.

Decryption

Encrypted archives are fully supported by Info-ZIP software, but due to United States export restrictions, de-/encryption support might be disabled in yourcompiled binary. However, since spring 2000, US export restrictions have been liberated, and our source archives do now include full crypt code. In case youneed binary distributions with crypt support enabled, see the file 'WHERE' in any Info-ZIP source or binary distribution for locations both inside andoutside the US.

Some compiled versions of unzip may not support decryption. To check a version for crypt support, either attempt to test or extract an encryptedarchive, or else check unzip's diagnostic screen (see the -v option above) for '[decryption]' as one of the special compilationoptions.

As noted above, the -P option may be used to supply a password on the command line, but at a cost in security. The preferred decryption method issimply to extract normally; if a zipfile member is encrypted, unzip will prompt for the password without echoing what is typed. unzip continuesto 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 theheader, 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 preventbrute-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 itpasses the header test anyway, either an incorrect CRC will be generated for the extracted data or else unzip will fail during the extraction becausethe 'decrypted' bytes do not constitute a valid compressed data stream.

If the first password fails the header check on some file, unzip will prompt for another password, and so on until all files are extracted. If apassword 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. Onlyunencrypted files in the archive(s) will thereafter be extracted. (In fact, that's not quite true; older versions of zip(1L) and zipcloak(1L)allowed null passwords, so unzip checks each encrypted file to see if the null password works. This may result in 'false positives' and extractionerrors, as noted above.)

Archives encrypted with 8-bit passwords (for example, passwords with accented European characters) may not be portable across systems and/or otherarchivers. This problem stems from the use of multiple encoding methods for such characters, including Latin-1 (ISO 8859-1) and OEM code page 850. DOSPKZIP 2.04g uses the OEM code page; Windows PKZIP 2.50 uses Latin-1 (and is therefore incompatible with DOS PKZIP); Info-ZIP uses the OEMcode page on DOS, OS/2 and Win3.x ports but ISO coding (Latin-1 etc.) everywhere else; and Nico Mak's WinZip 6.x does not allow 8-bit passwords at all.UnZip 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 testpasswords. 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, becausethere 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 UnZip 6.0 has not yet been adapted to the encryption password handling in unzip. On systems that use UTF-8 asnative character encoding, unzip simply tries decryption with the native UTF-8 encoded password; the built-in attempts to check the password intranslated encoding have not yet been adapted for UTF-8 support and will consequently fail.

Examples

To use unzip to extract all members of the archive letters.zip into the current directory and subdirectories below it, creating anysubdirectories as necessary:

To extract only newer versions of the files already in the current directory, without querying (NOTE: be careful of unzipping in one timezone a zipfilecreated in another--ZIP archives other than those created by Zip 2.1 or later contain no timezone information, and a 'newer' file from an eastern timezonemay, in fact, be older):
To extract newer versions of the files already in the current directory and to create any files not already there (same caveat as previous example):
To display a diagnostic screen showing which unzip and zipinfo options are stored in environment variables, whether decryption support wascompiled in, the compiler with which unzip was compiled, etc.:
In the last five examples, assume that UNZIP or UNZIP_OPTS is set to -q. To do a singly quiet listing:
To do a doubly quiet listing:
(Note that the '.zip' is generally not necessary.) To do a standard listing:
or
or
(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 ofdoing. With luck unzip will report 'No errors detected in compressed data of zipfile.zip,' after which one may breathe a sigh of relief.

The maintainer also finds it useful to set the UNZIP environment variable to '-aL' and is tempted to add '-C' as well. His ZIPINFOvariable 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 anyway. This includes zipfiles where one or more files was skipped due tounsupported 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 havesimple work-arounds.

3

a severe error in the zipfile format was detected. Processing probably failed immediately.

4

unzip was unable to allocate memory for one or more buffers during program initialization.

5

unzip was unable to allocate memory or unable to obtain a tty to read the decryption 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 command line.

11

no matching files were found.

50

the disk is (or was) full during extraction.

51

the end of the ZIP archive was encountered prematurely.

80

the user aborted unzip prematurely with control-C (or similar)

81

testing or extraction of one or more files failed due to unsupported compression methods or unsupported decryption.

82

no files were found due to bad decryption password(s). (If even one file is successfully 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. Thecurrent mapping is as follows: 1 (success) for normal exit, 0x7fff0001 for warning errors, and (0x7fff000? + 16*normal_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 acompilation 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 conjunction with zip. (All parts must be concatenated together in order, and then 'zip-F' (for zip 2.x) or 'zip -FF' (for zip 3.x) must be performed on the concatenated archive in order to 'fix' it. Also, zip3.0 and later can combine multi-part (split) archives into a combined single-file archive using 'zip -s- inarchive -O outarchive'. See thezip 3 manual page for more information.) 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. Seethe 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 correctwrapping locations. First, TAB characters (and similar control sequences) are not taken into account, they are handled as ordinary printable characters.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 console.

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 control-Break) canstill be used to terminate unzip.

Under DEC Ultrix, unzip would sometimes fail on long zipfiles (bad CRC, not always reproducible). This was apparently 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 notbe 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 inthe zipfile, 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 theoperating system; because directories only have a creation time associated with them, unzip has no way to determine whether the stored attributes arenewer or older than those on disk. In practice this may mean a two-pass approach is required: first unpack the archive normally (with or withoutfreshening/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 issilently 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 renaming; there should additionally be achoice for creating a new version of the file. In fact, the 'overwrite' choice does create a new version; the old version is not overwritten ordeleted.

See Also

funzip(1L), zip(1L), zipcloak(1L), zipgrep(1L), zipinfo(1L), zipnote(1L), zipsplit(1L)

Url

The Info-ZIP home page is currently at

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. Kirschbaumorganized 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 hasgrown quite large; please refer to the CONTRIBS file in the UnZip source distribution 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

Line
Info-ZIP (DPK, consolidator)
v3.1

15 Aug 90

Macos Unzip Command Line Windows

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

Macos Unzip Command Line Commands

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)
v5.4

28 Nov 98

Info-ZIP (Zip-Bugs subgroup, SPC)

Macos Unzip Command Line Ubuntu

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)
v6.0

20 Apr 09

Info-ZIP (Zip-Bugs subgroup, SPC)

Referenced By

gzip(1),mod_gridsite(8),unzipsfx(1),zipcloak(1),zipnote(1),zipsplit(1)