Updated to .NET Framework 4.7.2 due to platform limitations, added email cc, bcc and some fixes.
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
param(
|
||||
[string]$InstallPath = "C:\Program Files\JR IT Services\HostAvailabilityMonitor",
|
||||
[string]$ConfigRoot = "C:\ProgramData\JR IT Services\HostAvailabilityMonitor",
|
||||
[switch]$RemoveConfig
|
||||
)
|
||||
|
||||
Set-StrictMode -Version Latest
|
||||
$ErrorActionPreference = 'Stop'
|
||||
|
||||
if (Test-Path -LiteralPath $InstallPath) {
|
||||
Remove-Item -LiteralPath $InstallPath -Recurse -Force
|
||||
Write-Host "[INFO] Removed $InstallPath"
|
||||
}
|
||||
|
||||
if ($RemoveConfig -and (Test-Path -LiteralPath $ConfigRoot)) {
|
||||
Remove-Item -LiteralPath $ConfigRoot -Recurse -Force
|
||||
Write-Host "[INFO] Removed $ConfigRoot"
|
||||
}
|
||||
Reference in New Issue
Block a user