Windows 10 Scripts
MDT Image Cleanup
The following scripts are used to cleanup an MDT Image for the VAST lab.
Win10RemoveApps.ps1
This script removes default Windows 10 Apps that come pre-installed on the OS. The specific apps can be specified in the variable $AppsList
. To generate a list of currently installed Apps, run Get-AppxPackage | select name
MDT Quiet Install Command:
powershell.exe -ExecutionPolicy Bypass -Command "Copy-Item '%DEPLOYROOT%\Applications\Windows 10 App Removal\Win10RemoveApps.ps1' -destination C:\Windows\Temp; C:\Windows\Temp\Win10RemoveApps.ps1; Remove-Item C:\Windows\temp\Win10RemoveApps.ps1 -Force"
AppDataCleanup.ps1
This script removes directories in the Default Profile that cause new users to experience errors with some applications.
MDT Quiet Install Command:
powershell.exe -ExecutionPolicy Bypass -Command "Copy-Item '%DEPLOYROOT%\Applications\Windows 10 AppData Cleanup\AppDataCleanup.ps1' -destination C:\Windows\Temp; C:\Windows\Temp\AppDataCleanup.ps1; Remove-Item C:\Windows\temp\AppDataCleanup.ps1 -Force"
BootManagerCleanup.ps1
This script Removes the duplicate Windows Boot Manager
entries left by previous MDT images.
MDT Quiet Install Command:
powershell.exe -ExecutionPolicy Bypass -Command "Copy-Item '%DEPLOYROOT%\Applications\Windows 10 BootManager Cleanup\BootManagerCleanup.ps1' -destination C:\Windows\Temp; C:\Windows\Temp\BootManagerCleanup.ps1; Remove-Item C:\Windows\temp\BootManagerCleanup.ps1 -Force""
LicenseUnity.ps1
This script will fix Unity licensing issues by returning existing licenses, purging the ProgramData, and applying a new license.
MDT Quiet Install Command:
powershell.exe -ExecutionPolicy Bypass -Command "Copy-Item '%DEPLOYROOT%\Applications\Windows 10 License Unity\LicenseUnity.ps1' -destination C:\Windows\Temp; C:\Windows\Temp\LicenseUnity.ps1; Remove-Item C:\Windows\temp\LicenseUnity.ps1 -Force"