Last active
August 13, 2019 11:09
-
-
Save pmolchanov/d49330a170bbd3acf936160ca602a9a7 to your computer and use it in GitHub Desktop.
Silent Sysinternals Install
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
&{ | |
(New-Object System.Net.WebClient).DownloadFile( | |
"https://download.sysinternals.com/files/SysinternalsSuite.zip", | |
"$env:TEMP\SysinternalsSuite.zip") | |
$Shell = New-Object -com shell.application | |
$Zip = $Shell.NameSpace("$env:TEMP\SysinternalsSuite.zip") | |
New-Item -ItemType Directory -Force -Path "$env:ProgramFiles\SysinternalsSuite" | |
$Shell.Namespace("$env:ProgramFiles\SysinternalsSuite").CopyHere($Zip.Items()) | |
[Environment]::SetEnvironmentVariable( | |
"Path", | |
"$env:Path;$env:ProgramFiles\SysinternalsSuite", | |
[EnvironmentVariableTarget]::Machine) | |
$env:Path += ";$env:ProgramFiles\SysinternalsSuite" | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment