Modify the installation directory (Appx)

Discussion in 'Windows 10' started by tistou77, Jan 7, 2019.

  1. tistou77

    tistou77 MDL Expert

    Joined:
    Mar 22, 2008
    Messages:
    1,659
    Likes Received:
    550
    Trophy Points:
    60
    Hello

    I would like to "move" the .Appx installation directory that I install (Windows 10 1809)

    So I modified this registry key,

    [HKEY_LOCAL_MACHINE \ SOFTWARE \ Microsoft \ Windows \ CurrentVersion \ Appx]
    "PackageRoot" = "C:\Program Files\WindowsApps"

    But the apps still installs in C:\Program Files\WindowsApps
    Apps installed from an .appx file

    It is no longer possible to modify the installation directory ?

    Thanks
     
  2. GodHand

    GodHand MDL Addicted

    Joined:
    Jul 15, 2016
    Messages:
    534
    Likes Received:
    880
    Trophy Points:
    30
    Settings > System > Storage > "Change where new content is saved"
     
  3. tistou77

    tistou77 MDL Expert

    Joined:
    Mar 22, 2008
    Messages:
    1,659
    Likes Received:
    550
    Trophy Points:
    60
    Ok thanks,
    Will there be an option directly in regedit ?
     
  4. GodHand

    GodHand MDL Addicted

    Joined:
    Jul 15, 2016
    Messages:
    534
    Likes Received:
    880
    Trophy Points:
    30
    The path is saved to HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Appx\PackageRoot

    You can easily return it in PowerShell by querying it and expanding the PackageRoot property:
    Code:
    Get-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Appx" -Name PackageRoot | Select-Object -ExpandProperty PackageRoot
    
    Though I have not manually changed this path myself and have always just used Settings (I also do not keep my apps on my C drive).
     
  5. tistou77

    tistou77 MDL Expert

    Joined:
    Mar 22, 2008
    Messages:
    1,659
    Likes Received:
    550
    Trophy Points:
    60
    Thanks,
    I tested with the modification in the registry but it does not work :(
     
  6. tistou77

    tistou77 MDL Expert

    Joined:
    Mar 22, 2008
    Messages:
    1,659
    Likes Received:
    550
    Trophy Points:
    60
    Tested with the option Settings > System > Storage > "Change where new content is saved"
    It works but it installs directly to the root of the selected disk, not the choice of a directory / folder