Let’s continue with our automation scripting tool series. Doing things on windows by using the mouse manually is fun until you run into the need to go to a major OS upgrade and have tons of applications to reinstall. To avoid human errors and save lots of time, you can write a script to pick up your archived applications like tomcat zip files and unarchive it. This powershell scripts shows you how to unarchive a zip file silently.
#Unzip FIle Function
function Expand-ZIPFile($file, $destination)
{
$shell = new-object -com shell.application
$zip = $shell.NameSpace($file)
foreach($item in $zip.items())
{
$shell.Namespace($destination).copyhere($item)
}
}
# Call the function to unzip
$Origin_Zip_File=”C:\Document\Test.zip”
$Destination_Folder=”C:\Document\Test_Unzipped”
Expand-ZIPFile –File $Origin_Zip_File –Destination $Destination_Folder
Offering employees, coworkers, teammates, and students constructive feedback is a vital part of growth on…
Millennials should avoid delaying the inevitable and look into various retirement investment pathways. Here’s why…
For most people, a satisfactory career is essential for leading a happy life. However, ensuring…
The pipeline industry is more than pipework and construction, and we explore those details in…
SQL Interview Questions and Answers In the world of data-driven decision-making, SQL (Structured Query Language)…