diff --git a/install.bat b/install.bat index 611ed89..b82a95b 100644 --- a/install.bat +++ b/install.bat @@ -11,5 +11,5 @@ SET arguments=-UpdatesAtLogon -UpdatesInterval Weekly -InstallUserContext -Start :: Run Powershell Script :: :::::::::::::::::::::::::::: -SET PowershellCmd=Start-Process powershell.exe -Argument '-noprofile -executionpolicy bypass -file "%~dp0Winget-AutoUpdate-Install.ps1" %arguments% -powershell -Command "& {Get-ChildItem -Path '%~dp0' -Recurse | Unblock-File; %PowershellCmd%'}" -Verb RunAs +SET PowershellCmd=Start-Process powershell.exe -Verb RunAs -Argument '-noprofile -executionpolicy bypass -file "%~dp0Winget-AutoUpdate-Install.ps1" %arguments% +powershell -Command "& {Get-ChildItem -Path '%~dp0' -Recurse | Unblock-File; %PowershellCmd%'}" diff --git a/uninstall.bat b/uninstall.bat index 25a214a..9a33c87 100644 --- a/uninstall.bat +++ b/uninstall.bat @@ -11,5 +11,5 @@ SET arguments=-Uninstall :: Run Powershell Script :: :::::::::::::::::::::::::::: -SET PowershellCmd=Start-Process powershell.exe -Argument '-noprofile -executionpolicy bypass -file "%~dp0Winget-AutoUpdate-Install.ps1" %arguments% -powershell -Command "& {Get-ChildItem -Path '%~dp0' -Recurse | Unblock-File; %PowershellCmd%'}" -Verb RunAs +SET PowershellCmd=Start-Process powershell.exe -Verb RunAs -Argument '-noprofile -executionpolicy bypass -file "%~dp0Winget-AutoUpdate-Install.ps1" %arguments% +powershell -Command "& {Get-ChildItem -Path '%~dp0' -Recurse | Unblock-File; %PowershellCmd%'}"