Unzip .tar.gz files in Windows
Use this one-liner in the command prompt to extract the contents of .tar.gz files on Microsoft Windows machines.
Yes, it is possible to easily unzip tarballs in Windows! In order for the one-liner to work, you will first need to install 7-Zip, which is available free from the 7-Zip website. Note the location of
7za.exe on your Windows machine once installed.
Then open up the Command Prompt (type
cmd into the search bar/Cortana) and
cd to the directory where you want the file unzipped to.
The code is as follows; simply change the parameters to suit your circumstances.
c:\path\to\7za\7za.exe x c:\path\to\target\file.tar.gz -so | c:\path\to\7za\7za.exe x -si -ttar
The entire contents of the file should easily unzip.