mirror of
https://github.com/Icinga/icinga2.git
synced 2025-07-23 21:55:03 +02:00
Remove deprecated Chocolatey functions
This commit is contained in:
parent
025abc3357
commit
8096c3341f
@ -3,7 +3,6 @@ $fileType = 'msi';
|
|||||||
$silentArgs = '/qr /norestart'
|
$silentArgs = '/qr /norestart'
|
||||||
$validExitCodes = @(0)
|
$validExitCodes = @(0)
|
||||||
|
|
||||||
try {
|
|
||||||
$packageGuid = Get-ChildItem HKLM:\SOFTWARE\Classes\Installer\Products |
|
$packageGuid = Get-ChildItem HKLM:\SOFTWARE\Classes\Installer\Products |
|
||||||
Get-ItemProperty -Name 'ProductName' |
|
Get-ItemProperty -Name 'ProductName' |
|
||||||
? { $_.ProductName -like $packageName + "*"} |
|
? { $_.ProductName -like $packageName + "*"} |
|
||||||
@ -19,10 +18,3 @@ try {
|
|||||||
# Use this instead
|
# Use this instead
|
||||||
$msiArgs = "/x $file $silentArgs";
|
$msiArgs = "/x $file $silentArgs";
|
||||||
Start-ChocolateyProcessAsAdmin "$msiArgs" 'msiexec' -validExitCodes $validExitCodes
|
Start-ChocolateyProcessAsAdmin "$msiArgs" 'msiexec' -validExitCodes $validExitCodes
|
||||||
|
|
||||||
Write-ChocolateySuccess $package
|
|
||||||
}
|
|
||||||
catch {
|
|
||||||
Write-ChocolateyFailure $package "$($_.Exception.Message)"
|
|
||||||
throw
|
|
||||||
}
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user