WorkingDir

pull/339/head^2
Romain 2023-04-23 17:03:35 +02:00 committed by GitHub
parent a16313b367
commit 881ce2ddc1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -6,7 +6,7 @@ function Invoke-UserApproval ($outdated){
if ($IsSystem) { if ($IsSystem) {
$WAUClass = "HKLM:\Software\Classes\WAU" $WAUClass = "HKLM:\Software\Classes\WAU"
$WAUClassCmd = "$WAUClass\shell\open\command" $WAUClassCmd = "$WAUClass\shell\open\command"
$WAUClassRun = "Wscript.exe ""$WingetUpdatePath\Invisible.vbs"" ""powershell.exe -NoProfile -ExecutionPolicy Bypass -Command & '$WingetUpdatePath\User-Run.ps1' -NotifApproved %1""" $WAUClassRun = "Wscript.exe ""$WorkingDir\Invisible.vbs"" ""powershell.exe -NoProfile -ExecutionPolicy Bypass -Command & '$WorkingDir\User-Run.ps1' -NotifApproved %1"""
New-Item $WAUClassCmd -Force -ErrorAction SilentlyContinue | Out-Null New-Item $WAUClassCmd -Force -ErrorAction SilentlyContinue | Out-Null
New-ItemProperty -LiteralPath $WAUClass -Name 'URL Protocol' -Value '' -PropertyType String -Force -ErrorAction SilentlyContinue | Out-Null New-ItemProperty -LiteralPath $WAUClass -Name 'URL Protocol' -Value '' -PropertyType String -Force -ErrorAction SilentlyContinue | Out-Null
New-ItemProperty -LiteralPath $WAUClass -Name '(default)' -Value "URL:$($ActionType)" -PropertyType String -Force -ErrorAction SilentlyContinue | Out-Null New-ItemProperty -LiteralPath $WAUClass -Name '(default)' -Value "URL:$($ActionType)" -PropertyType String -Force -ErrorAction SilentlyContinue | Out-Null