Skip to content

Instantly share code, notes, and snippets.

@mkubenka mkubenka/clean.ps1
Last active Apr 30, 2017

What would you like to do?
Remove the ‘Modern apps’ (anything from the ‘Store’) from the profile you are using to create your Windows 10 image.
# Remove some Windows Store pakacges which are blocking Sysprep
# Execution of scripts has to be neabled: Set-ExecutionPolicy RemoteSigned
$AppsList = "Microsoft.Bing" , "Microsoft.BingFinance" , "Microsoft.BingMaps" , "Microsoft.BingNews"`
, "Microsoft.BingSports" , "Microsoft.BingTravel" , "Microsoft.BingWeather" , "Microsoft.Camera"`
, "microsoft.microsoftskydrive" , "Microsoft.Reader" , "microsoft.windowscommunicationsapps"`
, "microsoft.windowsphotos" , "Microsoft.XboxLIVEGames" , "Microsoft.ZuneMusic"`
, "Microsoft.ZuneVideo" , "Microsoft.Media.PlayReadyClient"
, "9E2F88E3.Twitter", ""
ForEach ($App in $AppsList)
$PackageFullName = (Get-AppxPackage $App).PackageFullName
if ((Get-AppxPackage $App).PackageFullName)
Write-Host "Removing Package: $App"
remove-AppxProvisionedPackage -online -packagename $PackageFullName
remove-AppxPackage -package $PackageFullName
Write-Host "Unable to find package: $App"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.