Question: write a script that takes a filename on the command line as its argument. If no file name is provided, print an error message and
write a script that takes a filename on the command line as its argument. If no file name is provided, print an error message and exit. The script should compress the file with each of these programs: gzip, bzip2, and zip. At each stage, gather the size of the file before and after compression. Then, display a report showing the compression program, the uncompressed size, the compressed size and the compression ratio (up to one decimal place). This output should be ordered by the compression achieved, with the most efficient compression featured first. In UNIX/LINUX
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
