Welcome to Shaun Luttin's public notebook. It contains rough, practical notes. The guiding idea is that, despite what marketing tells us, there are no experts at anything. Sharing our half-baked ideas helps everyone. We're all just muddling thru. Find out more about our work at bigfont.ca.

7zip - Extract an archive to a specific directory from the command line.

Tags: powershell, command-line, 7zip, productivity

Command Line

7z e foobar.zip -oFoobar

Yes. A space does not separate the -o switch from the destination directory.

PowerShell

& 7z e foobar.zip -oFoobar

Without an ampersand, PoSH will bark: "Bad numeric constant: 7."

See Also

PowerShell Special Tokens

7zip Command Line Docs