Linux unzip file from script without outputting the unzipped file names
7,176
From the MODIFIERS
section of man unzip
:
-q perform operations quietly (-qq = even quieter). Ordinarily unzip prints the names of the files it's extracting or testing, the extraction methods, any file or zipfile comments that may be stored in the archive, and possibly a summary when finished with each archive. The -q[q] options suppress the printing of some or all of these messages.
So
unzip -q filename.zip
Related videos on Youtube
Author by
Jim6834
Updated on September 18, 2022Comments
-
Jim6834 over 1 year
I unzipped a file from a script with "unzip filename.zip" and in the terminal I see all the unzipped file names. I would like to unzip the file without printing those names so that I have a clean terminal interface.
-
vaquito over 4 years
man unzip
is your friend.
-
-
Jim6834 over 4 yearsDoes that work also with move and copy? When I moved my files to another directories it displayed the whole process in the terminal just like it did with zip
-
steeldriver over 4 years@Jim6834 are you referring to the standard
mv
andcp
commands? if so, then AFAIK they don't report successful operations by default (they use-v
to increase the verbosity, rather than-q
to decrease it). Or are you moving/copying files some other way? -
Giacomo Alzetta over 4 years@Jim6834 If you want something that works with practically anything:
your command 2>/dev/null
.