Update Winget-Upgrade.ps1
parent
edfa1f1763
commit
a3e727ba34
|
@ -33,6 +33,10 @@ if ($IsSystem) {
|
|||
if (!(Test-Path -Path "${env:ProgramData}\Microsoft\IntuneManagementExtension\Logs\WAU-updates.log" -ErrorAction SilentlyContinue)) {
|
||||
$symLink = New-Item -Path "${env:ProgramData}\Microsoft\IntuneManagementExtension\Logs\WAU-updates.log" -ItemType SymbolicLink -Value $LogFile -Force -ErrorAction SilentlyContinue
|
||||
}
|
||||
# Check if install.log and symlink WAU-install.log exists, make symlink (doesn't work under ServiceUI)
|
||||
if ((Test-Path -Path ('{0}\logs\install.log' -f $WorkingDir) -ErrorAction SilentlyContinue) -and !(Test-Path -Path "${env:ProgramData}\Microsoft\IntuneManagementExtension\Logs\WAU-install.log" -ErrorAction SilentlyContinue)) {
|
||||
$symLink = (New-Item -Path "${env:ProgramData}\Microsoft\IntuneManagementExtension\Logs\WAU-install.log" -ItemType SymbolicLink -Value ('{0}\logs\install.log' -f $WorkingDir) -Force -Confirm:$False -ErrorAction SilentlyContinue)
|
||||
}
|
||||
}
|
||||
#Check if running with session ID 0
|
||||
if ($SessionID -eq 0) {
|
||||
|
|
Loading…
Reference in New Issue