In Linux, you can use zip
the command to compress files or directories. For example, to compress all files and folders in /home/html/
the directory to those in the current directory html.zip
, use the following command:
zip -q -r html.zip /home/html
Among them, -q
the option means quiet mode, and the execution process of the command is not displayed; -r
the option means recursive processing, and all files and subdirectories under the specified directory will be processed together. 1