Languages
[Edit]
EN

Linux - unpack zip file

15 points
Created by:
Remy-Lebe
832

In this short article, we would like to show how to unpack files from *.zip file using unzip under Linux.

Quick solution:

Where:

  • file.zip or /path/to/file.zip should be replaced with a desired zip file path.

Note: by default files will be extracted to the current working directory - check the below usage variants to see how to change output directory path (-d parameter).

 

Usage variants

Edit

In this section, you will see the most common unzip usage cases.

1. Unpack files into the indicated directory

Where:

  • -d ./output or -d /path/to/output indicate the location where files will be extracted.

2. Suppress unpacking messages

Where:

  • -q disables printing messages related to unpacking in the console.

3. Use zip archive password

Where:

  • -P "zip_file_password" indicates the password necessary to unpack the zip file.

4. Overwrite existing files without prompting

Where:

  • -o forces already extracted files overwriting (if there exists extracted file before - it will be overwritten)

     

      unzip command installation

      Edit

      To install under Debian/Ubuntu-based Linux it is necessary to use the following command:

      Alternative titles

      1. Linux - extract zip file
      2. Linux - unzip file
      1
      Donate to Dirask
      Our content is created by volunteers - like Wikipedia. If you think, the things we do are good, donate us. Thanks!
      Join to our subscribers to be up to date with content, news and offers.

      Linux

      Native Advertising
      🚀
      Get your tech brand or product in front of software developers.
      For more information Contact us
      Dirask - we help you to
      solve coding problems.
      Ask question.

      ❤️💻 🙂

      Join