Zip and Unzip in Termux – Compress and Extract ZIP Files

Zip and Unzip are simple command-line tools used to compress and extract ZIP files in Termux. It help you create ZIP archives, extract compressed files, and manage files and folders using simple commands. You can also use it for saving storage space, sharing files, and creating backups on your device.

Here’s what you can do with Zip and Unzip in Termux:

  • Compress files into ZIP archives.
  • Compress folders recursively.
  • Extract ZIP files.
  • View ZIP file contents.
  • Test ZIP archive integrity.
  • Create password-protected ZIP files.

Install Zip and Unzip in Termux

Below are the simple commands to install Zip and Unzip in Termux. Copy and run the command one by one to install the tools.

Update Termux packages.

pkg update && pkg upgrade -y

Install Zip.

pkg install zip -y

Install Unzip.

pkg install unzip -y

Zip and Unzip are now installed and ready to use.

Use Zip and Unzip in Termux

After installing Zip and Unzip, you can use different commands to compress files, extract ZIP archives, and manage compressed files.

Compress a file into a ZIP archive.

zip archive.zip file.txt

Compress a folder recursively.

zip -r archive.zip folder

Extract a ZIP file.

unzip archive.zip

Extract files to a specific directory.

unzip archive.zip -d output

List the contents of a ZIP file.

unzip -l archive.zip

Create a password-protected ZIP file.

zip -e secure.zip file.txt

Update an existing ZIP archive.

zip -u archive.zip file.txt

Delete a file from a ZIP archive.

zip -d archive.zip file.txt

Test the integrity of a ZIP archive.

zip -T archive.zip

Test a ZIP archive before extracting.

unzip -t archive.zip

Overwrite existing files while extracting.

unzip -o archive.zip

Show the Zip version.

zip -v

Show the Unzip version.

unzip -v

You can use these commands to compress, extract, test, and manage ZIP files easily in Termux.

End Note

Zip is useful for creating compressed files, while Unzip makes it easy to extract ZIP archives in Termux. Both tools are simple to use and help you manage files quickly on your Android device. You can also use them to organize and share files more easily.

SHARE THIS POST: