Get-AppxPackage -AllUsers <From WinPE>

~OSD~ 2,151 Reputation points
2021-02-03T13:30:29.09+00:00

Hi,

From running Windows (online) and from mounted .wim image (offline), I am able to retrieve the list of installed Appx Packages on a system using:

Get-AppxPackage -AllUsers | select Name,Version

OR Using DISM for the mounted .WIM image.

Is it possible to do the similar when booting from WinPE? The installation directory is C:\Windows ... can we get the AppxPackage list from WinPE?

Windows 10
Windows 10
A Microsoft operating system that runs on personal computers and tablets.
11,195 questions
Windows 10 Setup
Windows 10 Setup
Windows 10: A Microsoft operating system that runs on personal computers and tablets.Setup: The procedures involved in preparing a software program or application to operate within a computer or mobile device.
1,922 questions
Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,462 questions
0 comments No comments
{count} votes

Accepted answer
  1. ~OSD~ 2,151 Reputation points
    2021-02-04T19:30:50.97+00:00

    This means my thought was correct that we can't get AppxPackage list from WinPE without mounting the image.
    Thanks for confirmation.

    1 person found this answer helpful.
    0 comments No comments

3 additional answers

Sort by: Most helpful
  1. Sean Liming 4,591 Reputation points
    2021-02-03T16:55:34.55+00:00

    Yes, using WinPE + DISM you can get a list of packages for an offline image: Make Inventory of an Image or Component Using DISM


  2. Reza-Ameri 16,866 Reputation points
    2021-02-03T17:05:55.107+00:00

    WinPE supports command prompt and PowerShell is not supported there. However, you may open it and then type and enter PowerShell and press enter and it should load PowerShell and then you may type the above command.


  3. AliceYang-MSFT 2,091 Reputation points
    2021-02-04T07:47:50.93+00:00

    Hi,

    Offline servicing: Update Windows faster by using DISM to make your changes without ever booting Windows. Mount your image to a temporary location, install apps, drivers, languages, and more, and then commit the changes so they can be applied to new devices. DISM works from an elevated command-line or from PowerShell, which makes it easier to automate your changes with scripts.

    Offline means mount without booting Windows. I think it's unable to perform the task without mounting the image.

    ----------

    If the Answer is helpful, please click "Accept Answer" and upvote it.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments