mirror of
https://github.com/Baipyrus/dotfiles.git
synced 2024-12-26 03:11:45 +00:00
bugfix: call 'InstallWinget' with admin privileges
This commit is contained in:
parent
1e19a5e1cf
commit
9cc28a14e1
@ -13,7 +13,11 @@ function WingetInstall
|
|||||||
{
|
{
|
||||||
$install = Read-Host "Install WinGet now? [Y/n]"
|
$install = Read-Host "Install WinGet now? [Y/n]"
|
||||||
if ($install.ToLower() -ne 'n')
|
if ($install.ToLower() -ne 'n')
|
||||||
{ InstallWinget
|
{
|
||||||
|
# Start admin process, import this script, run 'InstallPackages' function
|
||||||
|
Start-Process powershell.exe -Verb RunAs `
|
||||||
|
-ArgumentList "-C", "'Import-Module ./winget.psm1; InstallWinget'"
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
winget.exe install -s winget --accept-source-agreements (Get-Content ./util/winget.list)
|
winget.exe install -s winget --accept-source-agreements (Get-Content ./util/winget.list)
|
||||||
|
Loading…
Reference in New Issue
Block a user