O'Reilly logo

Mac OS X in a Nutshell by Chris Stone, Chuck Toporek, Jason McIntosh

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Name

unzip

Synopsis

unzip [options[modifiers]] zipfile ... [extraction 
                     options]
unzip -Z [zipinfo 
                     options] zipfile ...

Unzip prints information about or extracts files from ZIP format archives. The zipfile is a ZIP archive whose filename ends in .zip. The .zip can be omitted from the command line; unzip supplies it. zipfile may also be a shell-style wildcard pattern (which should be quoted); all matching files in the ZIP archive will be acted upon. The behavior of options is affected by the various modifiers.

In the second form, the options are taken to be zipinfo options; unzip performs like that command.

Options may also be included in the UNZIP environment variable, to set a default behavior. Options on the command line can override settings in $UNZIP by preceding them with an extra minus. See the Examples.

When extracting files, if a file exists already, unzip prompts for an action. You may to choose to overwrite or skip the existing file, overwrite or skip all files, or rename the current file.

Notes

  • unzip and its companion program zip are part of the InfoZIP project. InfoZIP is an open collaborative compressed archive format, and implementations exist for Unix, Amiga, Atari, DEC VAX and Alpha VMS, OpenVMS, MS-DOS, Macintosh, Minix, OS/2, Windows NT, and many others. It is the only similar format one can expect to port to all of these systems without difficulty.

  • Unlike most Unix tar implementations, zip removes leading slashes when it creates a ZIP archive, so there is never ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required