0

My SOE builds have included a script to get rid of all but a few of the user based apps. The script has worked perfectly in all my builds up until Windows10 20H2. If I log into the workstation once the deployment has completed on a 20H2 build, all the user apps are still there... I can execute my script manually on the new target and it kills them off without issue. I hope MS are not forcing me down the app locker GPO path...

This is the script

# Remove most user provisioned apps

Set-ExecutionPolicy -ExecutionPolicy Bypass -Scope LocalMachine Get-AppxPackage -AllUsers | where-object {($.name –notlike “store”) -and ($.name –notlike "Calc") -and ($.name –notlike "alarms") -and ($.name –notlike "Camera") -and ($.name –notlike "Sticky")} | Remove-AppxPackage Get-appxprovisionedpackage –online | where-object {($.packagename –notlike “store”) -and ($.packagename –notlike "Calc") -and ($.packagename –notlike "alarms") -and ($.packagename –notlike "Camera") -and ($.packagename –notlike "Sticky")} | Remove-AppxProvisionedPackage -online

Anyone having the same or similar issue and can offer a work around?

Thanks in advance..

1 Answers1

0

Explicit naming of the apps (as per previous comment) seems to be the only way that works for 20H2 user based apps.