December 2015
Intermediate to advanced
760 pages
14h 31m
English
In this recipe, we will use the Compress-Archive cmdlet to compress or ZIP some files.
The following steps walk you through compressing files using PowerShell:
#replace the variable values with your #folder and destination file values #search for file with specific extension $folderToCompress = "C:\Temp\MyFiles" $destinationFile = $folderToCompress + ".zip" Compress-Archive -Path $folderToCompressfolderToCompress –DestinationPath $destinationFile –CompressionLevel Fastest -Update
PowerShell V5 introduces a new cmdlet that compresses files. Compress-Archive is an elegant way to archive or ZIP files. It accepts a folder or list ...
Read now
Unlock full access