How to Zip and Unzip in Linux

The Zip file format is used to archive and compress files. The zip utility can be used to combine several files into a single, compressed file, or it can be used to compress a single file. The zip format is a cross platform format, which means that a zip file created on a Windows computer can be extracted on a Linux computer. The Linux operating system uses the "zip" command to create zip files and the "unzip" command to extract zip files.

Instructions

  1. Zip

    • 1

      Open a terminal window. The terminal window application is found under the Accessories, System or Utilities sub-menu of the main menu.

    • 2

      Type the command "zip filename.zip file1 file2" to create the zip file. Replace "filename" with the name you want to give the zip file. Replace "file1" and "file2" with the names of the files you want contained in the archive. You can add as many files as you want to the zip file.

    • 3

      Type the command "ls *.zip" to ensure that the file was created correctly.

    • 4

      Type the command "exit" to close the terminal session.

    Unzip

    • 5

      Open a terminal window.

    • 6

      Type the command "unzip filename.zip" to unzip the file. Replace "filename" with the name of the zip file.

    • 7

      Type the command "ls -l" to list the files that were extracted from the zip file.

    • 8

      Type the command "exit" to close the terminal session.

Related Searches:

References

Comments

You May Also Like

Related Ads

Featured