In this blog, different methods have been explored by which we can zip a folder in Ubuntu 22.04.
There are two different methods to ZIP a folder in Ubuntu:
To zip a folder in Ubuntu, first install the ZIP utility in Ubuntu by executing the below-mentioned command:
To confirm the successful execution of the above command, check the installed version of ZIP utility:
In the above screenshot, the “Zip 3.0” is confirming that the utility of ZIP has installed.
What is the utilization of the ZIP utility in zip a folder?
The general syntax of using the ZIP utility to ZIP a folder is:
Following the above syntax:
Example
Suppose we have a directory with the name “LinuxHintFiles1” in our home directory and we want to compress it:
And this folder contains a couple of files in it as well:
In the above output, it can be seen that the folder, “LinuxHintFiles1” contains seven different files.
To zip the “LinuxHintFiles1” folder using the ZIP utility, use the below-mentioned command:
In the above command, the option “-r” of the ZIP utility has been used to move the folder into the zip file format.
To confirm the compression of the folder using the ZIP utility, again list down the contents of the directory:
In the above figure, the red color of the folder shows that it has been zipped. There are many other options that can be used with the ZIP utility and can be found by running the command:
Different options with their specific usage have been displayed on the screen.
To ZIP a folder through the GUI interface, right-click on the folder which is supposed to be archived:
Choose the “Compress…” option from the drop-down menu:
Type the name for the zipped folder and click on the “Create” button on the top of screen:
The Zipped folder has been created:
It can be verified that the zip folder has been created.
A Zip utility can be used to zip a folder using the command ”zip -r [name.zip] [folder name]” in Ubuntu 22.04 to change its format to archived. In this blog, the folder has been zipped by two different approaches, one is by using the GUI approach, and the other one is through the command-line interface.
One of the most critical gaps in traditional Large Language Models (LLMs) is that they…
Canonical is continuously hiring new talent. Being a remote- first company, Canonical’s new joiners receive…
What is patching automation? With increasing numbers of vulnerabilities, there is a growing risk of…
Wouldn’t it be wonderful to wake up one day with a desire to explore AI…
Ubuntu and Ubuntu Pro supports Microsoft’s Azure Cobalt 100 Virtual Machines (VMs), powered by their…
Welcome to the Ubuntu Weekly Newsletter, Issue 870 for the week of December 8 –…