adjusted for removal of Remove-File cmdlet
This commit is contained in:
@@ -28,5 +28,6 @@ Try { Set-MBSAgentSetting -Edition $AgentEdition -Verbose }
|
|||||||
Catch { Write-Error $_.Exception.Message }
|
Catch { Write-Error $_.Exception.Message }
|
||||||
|
|
||||||
# Delete the desktop icon
|
# Delete the desktop icon
|
||||||
"${Env:PUBLIC}\Desktop\Emberkom Backup.LNK",
|
Write-Output "Removing desktop icon"
|
||||||
"${Env:PUBLIC}\Desktop\Emberkom Cloud Backup.LNK" | Remove-File
|
Remove-Item -Path "${Env:PUBLIC}\Desktop\Emberkom Backup.LNK" -Force -ErrorAction SilentlyContinue
|
||||||
|
Remove-Item -Path "${Env:PUBLIC}\Desktop\Emberkom Cloud Backup.LNK" -Force -ErrorAction SilentlyContinue
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
# Run SFC to check the filesystem, convert the result from Unicode to UTF8, delete the intermediate $tempFile
|
# Run SFC to check the filesystem, convert the result from Unicode to UTF8, delete the intermediate $tempFile
|
||||||
$tempFile = Get-RandomTempFile
|
$tempFile = New-TemporaryFile
|
||||||
$(sfc.exe /scannow) | Out-File $tempFile
|
$(sfc.exe /scannow) | Out-File $tempFile
|
||||||
Set-Content -Path $tempFile -Value $(Get-Content -Path $tempFile -Encoding Unicode) -Encoding UTF8
|
Set-Content -Path $tempFile -Value $(Get-Content -Path $tempFile -Encoding Unicode) -Encoding UTF8
|
||||||
$SFCOutput = Get-Content -Path $tempFile
|
$SFCOutput = Get-Content -Path $tempFile
|
||||||
|
|||||||
@@ -29,7 +29,7 @@ If ( -not (Test-Path $SHORTCUT_PATH) ) {
|
|||||||
If ( $BROWSER_PATH ) {
|
If ( $BROWSER_PATH ) {
|
||||||
|
|
||||||
Write-Output "Installing Deltek Vision for ${APP_NAME}"
|
Write-Output "Installing Deltek Vision for ${APP_NAME}"
|
||||||
Create-Shortcut -Path "${Env:Public}\Desktop\Deltek Vision.lnk" -TargetPath $BROWSER_PATH -Arguments $VisionURL -Description "Launch Deltek Vision"
|
New-Shortcut -Path "${Env:Public}\Desktop\Deltek Vision.lnk" -TargetPath $BROWSER_PATH -Arguments $VisionURL -Description "Launch Deltek Vision"
|
||||||
}
|
}
|
||||||
Else { Write-Output "A compatible browser could not be found: ${BROWSER_PATH}" }
|
Else { Write-Output "A compatible browser could not be found: ${BROWSER_PATH}" }
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -42,5 +42,6 @@ Try { Set-MBSAgentSetting -Edition $AgentEdition -Verbose }
|
|||||||
Catch { Write-Error $_.Exception.Message }
|
Catch { Write-Error $_.Exception.Message }
|
||||||
|
|
||||||
# Delete the desktop icon
|
# Delete the desktop icon
|
||||||
"${Env:PUBLIC}\Desktop\Emberkom Backup.LNK",
|
Write-Output "Removing desktop icon"
|
||||||
"${Env:PUBLIC}\Desktop\Emberkom Cloud Backup.LNK" | Remove-File
|
Remove-Item -Path "${Env:PUBLIC}\Desktop\Emberkom Backup.LNK" -Force -ErrorAction SilentlyContinue
|
||||||
|
Remove-Item -Path "${Env:PUBLIC}\Desktop\Emberkom Cloud Backup.LNK" -Force -ErrorAction SilentlyContinue
|
||||||
@@ -22,7 +22,7 @@ If ( IsAdmin )
|
|||||||
|
|
||||||
## Create shortcut on Public desktop
|
## Create shortcut on Public desktop
|
||||||
If ( $CreateDesktopShortcut ) {
|
If ( $CreateDesktopShortcut ) {
|
||||||
Create-Shortcut -Path "${Env:Public}\Desktop\WireGuard VPN.LNK" -TargetPath "${Env:ProgramFiles}\WireGuard\wireguard.exe" -Description "WireGuard: Fast, Modern, Secure VPN Tunnel"
|
New-Shortcut -Path "${Env:Public}\Desktop\WireGuard VPN.LNK" -TargetPath "${Env:ProgramFiles}\WireGuard\wireguard.exe" -Description "WireGuard: Fast, Modern, Secure VPN Tunnel"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Else { Write-Output "Must be an administrator to install WireGuard" }
|
Else { Write-Output "Must be an administrator to install WireGuard" }
|
||||||
@@ -1,7 +0,0 @@
|
|||||||
$LogsToEnable = @(
|
|
||||||
''
|
|
||||||
)
|
|
||||||
|
|
||||||
ForEach ( $log in $LogsToEnable ) {
|
|
||||||
Toggle-Log -Name $log -Enable
|
|
||||||
}
|
|
||||||
Reference in New Issue
Block a user