7-Zip command line: Extract silently/quietly [duplicate]

Possible Duplicate:
How to disable the output of 7-Zip?

I want to use 7z.exe from a command prompt to silently/quietly extract an archive. I do not want to use third-party scripts or APIs. Does 7-Zip have native support for quiet command-line extraction?


Solution 1:

7-Zip does not have an explicit "quiet" or "silent" mode for command line extraction.

A similar question over at Stack Overflow, Extracting a 7-Zip file "silently" - command line option, gives a possible solution using Python scripting code:

One possibility would be to spawn the child process with popen, so its output will come back to the parent to be processed/displayed (if desired) or else completely ignored (create your popen object with stdout=PIPE and stderr=PIPE to be able to retrieve the output from the child).

And then a similar question here on Super User, Redirect 7-Zip's command-line output to /dev/null on Windows when extracting a .7z file reports that the issue is mostly the output, and that by sending the output to NULL, you make the system run essentially silent:

Try doing this:

%COMSPEC% /c "%ProgramFiles%\7-Zip\7z.exe" ...