How can I see the install scope of an already installed package, that has been previously with installed using winget
?
winget install --scope machine -i -e xxxx
Use winget list
with --scope machine
, but note that you need to run from an elevated session (not necessary for --scope user
):
# REQUIRES ELEVATION
winget list --scope machine
Update:
There's now an official PowerShell module, Microsoft.WinGet.Client
which provides the same functionality as winget.exe
in a PowerShell-friendly and therefore object-based manner; for instance, the equivalent of winget.exe list
is Get-WinGetPackage
. You can install the module by running, e.g.,
Install-Module -Scope CurrentUser Microsoft.WinGet.Client
.
However, as of module version 1.9.25190, there does not seem to be functionality that is equivalent to --scope machine
.