Unfortunately it is not possible to compress or extract zipped files using cmdlets in PowerShell. This feature will be introduced in PowerShell 5.0, but for the time being using the System.IO.Compression.ZipFile class can be a nice workaround. The full article is available on PowerShell Magazine : Compress files and folders with System.IO.Compression.FileSystem class
1 | [System.IO.Compression.ZipFile]::ExtractToDirectory('c:testing.zip', 'c:newtest') |
For more articles like this, have a look at the External Articles section of my blog, it contains all the articles I have posted on external sources such as PowerShell Magazine.
Links in this Article |
PSTip: Compress files and folders with System.IO.Compression.FileSystem class |
PowerShell Magazine |
External Articles |
Pingback: Determine compression ratio | Jaap Brasser's Blog