Verify explorer.exe is running it before stopping it

Issue #578
This commit is contained in:
Chris Long authored and GitHub committed 2020-12-20 20:35:04 -08:00
1 parent 1a4509c340
commit cad9c0e553
1 file changed
+2
+2
View File
@@ -93,7 +93,9 @@ $Shortcut.TargetPath = $tcpviewPath
$Shortcut.Save() $Shortcut.Save()
# Restart Explorer so the taskbar shortcuts show up # Restart Explorer so the taskbar shortcuts show up
if (Get-Process -ProcessName explorer -ErrorAction 'silentlycontinue') {
Stop-Process -ProcessName explorer -Force Stop-Process -ProcessName explorer -Force
}
# Download Olaf Hartongs Sysmon config # Download Olaf Hartongs Sysmon config
Write-Host "$('[{0:HH:mm}]' -f (Get-Date)) Downloading Olaf Hartong's Sysmon config..." Write-Host "$('[{0:HH:mm}]' -f (Get-Date)) Downloading Olaf Hartong's Sysmon config..."